From: Saint Xavier Date: Thu, 19 Jun 2008 21:53:03 +0000 (+0200) Subject: Set an initial value for IRIs options and some minor additions in iri.c X-Git-Tag: v1.13~338^2~7^2~6^2~13^2~24 X-Git-Url: http://sjero.net/git/?p=wget;a=commitdiff_plain;h=be546c20cb08f9c25a6bd98bcdf44394e3e8a846 Set an initial value for IRIs options and some minor additions in iri.c --- diff --git a/src/ChangeLog b/src/ChangeLog index ef69dca6..7ad7c8ca 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,11 @@ +2008-06-19 Xavier Saint + + * iri.c : Include missing stringprep.h file and add a + cast. + + * init.c : set a default initial value for opt.enable_iri, + opt.locale and opt.encoding_remote. + 2008-06-19 Xavier Saint * iri.c, iri.h : Add a new function find_locale() to find diff --git a/src/init.c b/src/init.c index a7a4ee01..f56aa652 100644 --- a/src/init.c +++ b/src/init.c @@ -333,6 +333,14 @@ defaults (void) opt.restrict_files_case = restrict_no_case_restriction; opt.max_redirect = 20; + +#ifdef ENABLE_IRI + opt.enable_iri = true; +#else + opt.enable_iri = false; +#endif + opt.locale = NULL; + opt.encoding_remote = NULL; } /* Return the user's home directory (strdup-ed), or NULL if none is diff --git a/src/iri.c b/src/iri.c index 797ffa44..b87e6ebe 100644 --- a/src/iri.c +++ b/src/iri.c @@ -35,6 +35,8 @@ as that of the covered work. */ #include #include +#include + #include "utils.h" #include "iri.h" @@ -73,7 +75,7 @@ char * find_locale (void) { /* sXXXav, made our own function or use libidn one ?! */ - return stringprep_locale_charset (); + return (char *) stringprep_locale_charset (); }