X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;ds=sidebyside;f=avahi-common%2Fmalloc.c;h=52e0962df25a25607f221435d2f16593b5fd8222;hb=0433169ea9c6906f31b1a78e9a118858dd776dad;hp=0dd4eb0db6e31b4768f70d47cab7024a85f26ee8;hpb=c0eb12ae8965571be6afe8c02e5f9d9cc70d073a;p=catta diff --git a/avahi-common/malloc.c b/avahi-common/malloc.c index 0dd4eb0..52e0962 100644 --- a/avahi-common/malloc.c +++ b/avahi-common/malloc.c @@ -207,7 +207,9 @@ char *avahi_strdup_vprintf(const char *fmt, va_list ap) { va_copy (ap2, ap); - n = vsnprintf(buf, len, fmt, ap); + n = vsnprintf(buf, len, fmt, ap2); + + va_end (ap2); if (n >= 0 && n < (int) len) return buf;