X-Git-Url: http://sjero.net/git/?p=wget;a=blobdiff_plain;f=src%2Fhtml-url.c;h=0d580f9aaf74b3df8032756fc0ac929b541ea540;hp=9b515432a8122550b9beaca988bce6e99d1c16dd;hb=9a2ea3938d09643c6528c3b83b1db4c30f47d981;hpb=6c6e838338c31f1ac3c57c71e4ac34c0401bdf86 diff --git a/src/html-url.c b/src/html-url.c index 9b515432..0d580f9a 100644 --- a/src/html-url.c +++ b/src/html-url.c @@ -274,6 +274,7 @@ append_url (const char *link_uri, struct urlpos *newel; const char *base = ctx->base ? ctx->base : ctx->parent_base; struct url *url; + bool utf8_encode = false; if (!base) { @@ -292,7 +293,7 @@ append_url (const char *link_uri, return NULL; } - url = url_parse (link_uri, NULL); + url = url_parse (link_uri, NULL, &utf8_encode); if (!url) { DEBUGP (("%s: link \"%s\" doesn't parse.\n", @@ -311,7 +312,7 @@ append_url (const char *link_uri, DEBUGP (("%s: merge(\"%s\", \"%s\") -> %s\n", ctx->document_file, base, link_uri, complete_uri)); - url = url_parse (complete_uri, NULL); + url = url_parse (complete_uri, NULL, &utf8_encode); if (!url) { DEBUGP (("%s: merged link \"%s\" doesn't parse.\n", @@ -549,9 +550,9 @@ tag_handle_meta (int tagid, struct taginfo *tag, struct map_context *ctx) if (!mcharset) return; - logprintf (LOG_VERBOSE, "Meta tag charset : %s\n", quote (mcharset)); + /*logprintf (LOG_VERBOSE, "Meta tag charset : %s\n", quote (mcharset));*/ - /* sXXXav: Not used yet */ + set_current_charset (mcharset); xfree (mcharset); } else if (name && 0 == strcasecmp (name, "robots")) @@ -660,6 +661,7 @@ get_urls_file (const char *file) struct file_memory *fm; struct urlpos *head, *tail; const char *text, *text_end; + bool utf8_encode = false; /* Load the file. */ fm = read_file (file); @@ -711,7 +713,7 @@ get_urls_file (const char *file) url_text = merged; } - url = url_parse (url_text, &up_error_code); + url = url_parse (url_text, &up_error_code, &utf8_encode); if (!url) { logprintf (LOG_NOTQUIET, _("%s: Invalid URL %s: %s\n"),