Skip to content

Commit e6156a0

Browse files
committed
Merge #10056: [zmq] Call va_end() on va_start()ed args.
5ba61f0 [zmq] Call va_end() on va_start()ed args. (Karl-Johan Alm) Tree-SHA512: fbd3a0c29308ca9607f362f14fa7ea9c949a3f25dc09a349fe3b3ffd316b573c86778e29d3b9d55c684571eacae50aca90bb872e2e5489818d0af8310511fe79
2 parents 0ddea44 + 5ba61f0 commit e6156a0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/zmq/zmqpublishnotifier.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ static int zmq_send_multipart(void *sock, const void* data, size_t size, ...)
3030
if (rc != 0)
3131
{
3232
zmqError("Unable to initialize ZMQ msg");
33+
va_end(args);
3334
return -1;
3435
}
3536

@@ -43,6 +44,7 @@ static int zmq_send_multipart(void *sock, const void* data, size_t size, ...)
4344
{
4445
zmqError("Unable to send ZMQ msg");
4546
zmq_msg_close(&msg);
47+
va_end(args);
4648
return -1;
4749
}
4850

@@ -53,6 +55,7 @@ static int zmq_send_multipart(void *sock, const void* data, size_t size, ...)
5355

5456
size = va_arg(args, size_t);
5557
}
58+
va_end(args);
5659
return 0;
5760
}
5861

0 commit comments

Comments
 (0)