aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorGisle Vanem <gvanem@broadpark.no>2007-03-28 04:23:33 +0000
committerGisle Vanem <gvanem@broadpark.no>2007-03-28 04:23:33 +0000
commit25c064c8888134be91e157d6542e4667b8cf5742 (patch)
treeeb88f623da85cb6ba4404a130315d8c3078796df /lib
parent884171aecf890057e5700221e15a3cf711dc7e9e (diff)
Simplified code around 'tld_errmsg' a bit.
Diffstat (limited to 'lib')
-rw-r--r--lib/url.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/lib/url.c b/lib/url.c
index 43853f367..95eab6da1 100644
--- a/lib/url.c
+++ b/lib/url.c
@@ -2490,10 +2490,7 @@ static bool tld_check_name(struct SessionHandle *data,
char *uc_name = NULL;
int rc;
#ifndef CURL_DISABLE_VERBOSE_STRINGS
- char *tld_errmsg;
-#ifndef HAVE_TLD_STRERROR
- char no_msg[] = "<no msg>";
-#endif
+ char *tld_errmsg = "<no msg>";
#else
(void)data;
#endif
@@ -2508,8 +2505,6 @@ static bool tld_check_name(struct SessionHandle *data,
if (rc != TLD_SUCCESS)
#ifdef HAVE_TLD_STRERROR
tld_errmsg = (char *)tld_strerror((Tld_rc)rc);
-#else
- tld_errmsg = no_msg;
#endif
if (rc == TLD_INVALID)
infof(data, "WARNING: %s; pos %u = `%c'/0x%02X\n",