[project @ 2004-01-24 16:41:52 by jmb]

Strip leading and trailing whitespace from image src attributes.

svn path=/import/netsurf/; revision=499
This commit is contained in:
John Mark Bell 2004-01-24 16:41:52 +00:00
parent 8755ceb0c8
commit b116f20cd4
1 changed files with 3 additions and 0 deletions

View File

@ -736,6 +736,9 @@ struct result box_image(xmlNode *n, struct status *status,
if (!(s = (char *) xmlGetProp(n, (const xmlChar *) "src")))
return (struct result) {box, 0};
/* remove leading and trailing whitespace */
s = strip(s);
url = url_join(s, status->content->data.html.base_url);
if (!url)
return (struct result) {box, 0};