"An, Young Hun" <[EMAIL PROTECTED]> writes: > if HTML document contains code like this > > <meta http-equiv=Refresh> > > wget may be crushed. It has 'refresh' but > does not have 'content'. Of course this is > incorrect HTML. But I found some pages at web :) > > simply add check routine at 'tag_handle_meta' function.
Thanks for the report; this patch should fix the bug: 2002-02-01 Hrvoje Niksic <[EMAIL PROTECTED]> * html-url.c (tag_handle_meta): Don't crash on <meta http-equiv=refresh> where content is missing. Index: src/html-url.c =================================================================== RCS file: /pack/anoncvs/wget/src/html-url.c,v retrieving revision 1.23 diff -u -r1.23 html-url.c --- src/html-url.c 2001/12/19 01:15:34 1.23 +++ src/html-url.c 2002/02/01 03:32:55 @@ -521,10 +521,13 @@ get to the URL. */ struct urlpos *entry; - int attrind; - char *p, *refresh = find_attr (tag, "content", &attrind); int timeout = 0; + char *p; + + char *refresh = find_attr (tag, "content", &attrind); + if (!refresh) + return; for (p = refresh; ISDIGIT (*p); p++) timeout = 10 * timeout + *p - '0';