aboutsummaryrefslogtreecommitdiffstats
path: root/cli.c
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-07-27 01:29:57 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-07-27 01:29:57 +0000
commit3336dbf9857f0db05c25391089b5f2dec6c36135 (patch)
tree9227e954561ac259e4f3bfe908478a396d7cccb6 /cli.c
parentf6647e8d2250bf717a46ecb5167dbae8d5a899d1 (diff)
fix some breakage of ast_cli() that resulted in seg faults on Josh's machine.
I'm not sure why this never caused problems for me ... git-svn-id: http://svn.digium.com/svn/asterisk/trunk@38283 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'cli.c')
-rw-r--r--cli.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/cli.c b/cli.c
index f411229cd..205ef7f7a 100644
--- a/cli.c
+++ b/cli.c
@@ -88,6 +88,8 @@ void ast_cli(int fd, char *fmt, ...)
}
buf->len *= 2;
pthread_setspecific(ast_cli_buf_key, buf);
+ va_end(ap);
+ va_start(ap, fmt);
res = vsnprintf(buf->str, buf->len, fmt, ap);
}
va_end(ap);