Commit ca42915c authored by Federico G. Schwindt's avatar Federico G. Schwindt

Always call va_end()

parent 3ccc7fbf
......@@ -355,11 +355,11 @@ VSB_vprintf(struct vsb *s, const char *fmt, va_list ap)
va_copy(ap_copy, ap);
len = vsnprintf(&s->s_buf[s->s_len], VSB_FREESPACE(s) + 1,
fmt, ap_copy);
va_end(ap_copy);
if (len < 0) {
s->s_error = errno;
return (-1);
}
va_end(ap_copy);
} while (len > VSB_FREESPACE(s) &&
VSB_extend(s, len - VSB_FREESPACE(s)) == 0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment