summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAndrew Kroeger <andrew@id10ts.net>2009-06-12 13:01:41 +0200
committerAndrew Bartlett <abartlet@samba.org>2009-06-18 13:49:25 +1000
commit71515ba190e90e0250b9de23b7ba871c1dd44f09 (patch)
tree88217cd2054ab02cbdc88aa9df620112572318e0 /lib
parentefe6552f0c1b2cf7e7f95987e7c808667166a303 (diff)
downloadsamba-71515ba190e90e0250b9de23b7ba871c1dd44f09.tar.gz
samba-71515ba190e90e0250b9de23b7ba871c1dd44f09.tar.bz2
samba-71515ba190e90e0250b9de23b7ba871c1dd44f09.zip
s4: Call va_end() after all va_start()/va_copy() calls.
This corrects the issues reaised in bug #6129, and some others that were not originally identified. It also accounts for some code that was in the original bug report but appears to have since been made common between S3 and S4. Thanks to Erik Hovland <erik@hovland.org> for the original bug report.
Diffstat (limited to 'lib')
-rw-r--r--lib/torture/torture.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/torture/torture.c b/lib/torture/torture.c
index 17adce94e5..99447e7e53 100644
--- a/lib/torture/torture.c
+++ b/lib/torture/torture.c
@@ -107,6 +107,7 @@ void torture_comment(struct torture_context *context, const char *comment, ...)
va_start(ap, comment);
tmp = talloc_vasprintf(context, comment, ap);
+ va_end(ap);
context->results->ui_ops->comment(context, tmp);
@@ -126,6 +127,7 @@ void torture_warning(struct torture_context *context, const char *comment, ...)
va_start(ap, comment);
tmp = talloc_vasprintf(context, comment, ap);
+ va_end(ap);
context->results->ui_ops->warning(context, tmp);