summaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
authorTony Cook <tony@develop-help.com>2014-05-22 11:05:59 +1000
committerTony Cook <tony@develop-help.com>2014-05-29 16:23:11 +1000
commitd4825b278e28006bdc9c3f36ab174eade62d6c4c (patch)
tree714a9ee65793a717abee083173209c9873831da5 /util.c
parentfe2ce09d592612ace5bf8acccba9db512adb54a5 (diff)
downloadperl-d4825b278e28006bdc9c3f36ab174eade62d6c4c.tar.gz
put va_end() in the right place
Diffstat (limited to 'util.c')
-rw-r--r--util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util.c b/util.c
index 4daf01d95b..39b24f01e0 100644
--- a/util.c
+++ b/util.c
@@ -4928,6 +4928,7 @@ Perl_my_vsnprintf(char *buffer, const Size_t len, const char *format, va_list ap
# else
retval = vsprintf(buffer, format, apc);
# endif
+ va_end(apc);
#else
# ifdef HAS_VSNPRINTF
retval = vsnprintf(buffer, len, format, ap);
@@ -4935,7 +4936,6 @@ Perl_my_vsnprintf(char *buffer, const Size_t len, const char *format, va_list ap
retval = vsprintf(buffer, format, ap);
# endif
#endif /* #ifdef NEED_VA_COPY */
- va_end(apc);
/* vsprintf() shows failure with < 0 */
if (retval < 0
#ifdef HAS_VSNPRINTF