aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2004-06-24 14:52:51 +0000
committerDaniel Stenberg <daniel@haxx.se>2004-06-24 14:52:51 +0000
commit8b6b15dcccbe2c137a33b01370fe804462c950a6 (patch)
tree3819583bab2eae98205c174c0724b593f8ef663d /lib
parentbbb72b7b6bee046656aab0188c9c5e514825aed0 (diff)
to prevent compier warnings, we only declare len if we have code
that uses it
Diffstat (limited to 'lib')
-rw-r--r--lib/version.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/version.c b/lib/version.c
index 21939d925..510c20afc 100644
--- a/lib/version.c
+++ b/lib/version.c
@@ -102,7 +102,12 @@ char *curl_version(void)
{
static char version[200];
char *ptr=version;
+ /* to prevent compier warnings, we only declare len if we have code
+ that uses it */
+#if defined(USE_SSLEAY) || defined(HAVE_LIBZ) || defined(USE_ARES) || \
+ defined(USE_LIBIDN)
int len;
+#endif
size_t left = sizeof(version);
strcpy(ptr, LIBCURL_NAME "/" LIBCURL_VERSION );
ptr=strchr(ptr, '\0');