diff options
Diffstat (limited to 'sshbuf-getput-basic.c')
-rw-r--r-- | sshbuf-getput-basic.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sshbuf-getput-basic.c b/sshbuf-getput-basic.c index ad21ae574..74c49be7c 100644 --- a/sshbuf-getput-basic.c +++ b/sshbuf-getput-basic.c | |||
@@ -270,7 +270,7 @@ sshbuf_putfv(struct sshbuf *buf, const char *fmt, va_list ap) | |||
270 | int r, len; | 270 | int r, len; |
271 | u_char *p; | 271 | u_char *p; |
272 | 272 | ||
273 | va_copy(ap2, ap); | 273 | VA_COPY(ap2, ap); |
274 | if ((len = vsnprintf(NULL, 0, fmt, ap2)) < 0) { | 274 | if ((len = vsnprintf(NULL, 0, fmt, ap2)) < 0) { |
275 | r = SSH_ERR_INVALID_ARGUMENT; | 275 | r = SSH_ERR_INVALID_ARGUMENT; |
276 | goto out; | 276 | goto out; |
@@ -280,7 +280,7 @@ sshbuf_putfv(struct sshbuf *buf, const char *fmt, va_list ap) | |||
280 | goto out; /* Nothing to do */ | 280 | goto out; /* Nothing to do */ |
281 | } | 281 | } |
282 | va_end(ap2); | 282 | va_end(ap2); |
283 | va_copy(ap2, ap); | 283 | VA_COPY(ap2, ap); |
284 | if ((r = sshbuf_reserve(buf, (size_t)len + 1, &p)) < 0) | 284 | if ((r = sshbuf_reserve(buf, (size_t)len + 1, &p)) < 0) |
285 | goto out; | 285 | goto out; |
286 | if ((r = vsnprintf((char *)p, len + 1, fmt, ap2)) != len) { | 286 | if ((r = vsnprintf((char *)p, len + 1, fmt, ap2)) != len) { |