curl-shim: clean up varargs
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Wed, 18 Feb 2015 09:11:31 +0000 (04:11 -0500)
committerWerner Koch <wk@gnupg.org>
Wed, 18 Feb 2015 11:26:11 +0000 (12:26 +0100)
* keyserver/curl-shim.c (curl_easy_setopt) : ensure that va_end is
  called.

--

stdarg(3) says:
      Each invocation of va_start() must be matched by a
      corresponding invocation of va_end() in the same function.

Observed by Joshua Rogers <honey@internot.info>

Debian-Bug-Id: #773475

keyserver/curl-shim.c

index be87780..93d05b0 100644 (file)
@@ -165,6 +165,8 @@ curl_easy_setopt(CURL *curl,CURLoption option,...)
       break;
     }
 
+  va_end(ap);
+
   return handle_error(curl,CURLE_OK,NULL);
 }