mirror of
https://github.com/libretro/RetroArch
synced 2025-03-01 07:13:35 +00:00
N/A
This commit is contained in:
parent
bfd0aa18e4
commit
43459e2269
@ -46,10 +46,12 @@ int string_parse_html_anchor(const char *line, char *link, char *name,
|
||||
memset(link, 0, link_size);
|
||||
memset(name, 0, name_size);
|
||||
|
||||
if(!(line = strcasestr(line, "<a href=\"")))
|
||||
line = strcasestr(line, "<a href=\"");
|
||||
|
||||
if (!line)
|
||||
return 1;
|
||||
else
|
||||
line += 9;
|
||||
|
||||
line += 9;
|
||||
|
||||
if (line && *line)
|
||||
{
|
||||
@ -69,7 +71,7 @@ int string_parse_html_anchor(const char *line, char *link, char *name,
|
||||
if (!*name)
|
||||
{
|
||||
char *start = strstr(line, "\">");
|
||||
char *end = strstr(start, "</a>");
|
||||
char *end = strstr(start, "</a>");
|
||||
|
||||
if (!start || !end)
|
||||
return 1;
|
||||
@ -88,7 +90,7 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
char link[1024];
|
||||
char name[1024];
|
||||
const char *line = "<a href=\"http://www.test.com/somefile.zip\">Test</a>\n";
|
||||
const char *line = "<a href=\"http://www.test.com/somefile.zip\">Test</a>\n";
|
||||
|
||||
link[0] = name[0] = '\0';
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user