aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2007-03-28 19:05:43 +0000
committerYang Tse <yangsita@gmail.com>2007-03-28 19:05:43 +0000
commitbfa0f8c6c271460de31d42eb99d8c4e3a5e12486 (patch)
tree00d35b5615e497630976ec53c4cd04723720fa28
parent869d192ffc6b47ebc9fec75ace8fbbe2d50c5d0f (diff)
fix compiler warning
-rw-r--r--lib/url.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/lib/url.c b/lib/url.c
index 3eec1ccad..3aa7bdcc2 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -2490,7 +2490,7 @@ static bool tld_check_name(struct SessionHandle *data,
char *uc_name = NULL;
int rc;
#ifndef CURL_DISABLE_VERBOSE_STRINGS
- char *tld_errmsg = "<no msg>";
+ char *tld_errmsg = (char *)"<no msg>";
#else
(void)data;
#endif
@@ -2523,6 +2523,13 @@ static bool tld_check_name(struct SessionHandle *data,
static void fix_hostname(struct SessionHandle *data,
struct connectdata *conn, struct hostname *host)
{
+#ifndef USE_LIBIDN
+ (void)data;
+ (void)conn;
+#elif defined(CURL_DISABLE_VERBOSE_STRINGS)
+ (void)conn;
+#endif
+
/* set the name we use to display the host name */
host->dispname = host->name;
@@ -2549,12 +2556,6 @@ static void fix_hostname(struct SessionHandle *data,
host->name = host->encalloc;
}
}
-#else
- (void)data; /* never used */
- (void)conn; /* never used */
-#endif
-#ifdef CURL_DISABLE_VERBOSE_STRINGS
- (void)conn; /* never used */
#endif
}