X-Git-Url: http://sjero.net/git/?p=wget;a=blobdiff_plain;f=src%2Furl.c;h=4c22a9fc6e460c5d34cc63ac81f0d6d3ca69c453;hp=86d099a7190b80aaec8bc1cf6771c49892364602;hb=4f3dd6817348433eafde04a3c2946f43364de7ef;hpb=5d0073b8f290dee2e9bad3e83230f6b57dd06beb diff --git a/src/url.c b/src/url.c index 86d099a7..4c22a9fc 100644 --- a/src/url.c +++ b/src/url.c @@ -668,7 +668,8 @@ url_parse (const char *url, int *error, struct iri *iri, bool percent_encode) int port; char *user = NULL, *passwd = NULL; - char *url_encoded = NULL, *new_url = NULL; + const char *url_encoded = NULL; + char *new_url = NULL; int error_code; @@ -904,7 +905,7 @@ url_parse (const char *url, int *error, struct iri *iri, bool percent_encode) if (url_encoded == url) u->url = xstrdup (url); else - u->url = url_encoded; + u->url = (char *) url_encoded; } return u; @@ -912,7 +913,7 @@ url_parse (const char *url, int *error, struct iri *iri, bool percent_encode) error: /* Cleanup in case of error: */ if (url_encoded && url_encoded != url) - xfree (url_encoded); + xfree ((char *) url_encoded); /* Transmit the error code to the caller, if the caller wants to know. */