Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

va_copy must be followed by va_end #178

Merged
merged 1 commit into from

2 participants

Richard Fuchs Pieter Noordhuis
Richard Fuchs

... otherwise memory leak might result.

Pieter Noordhuis pietern merged commit 17d73ef into from
Pieter Noordhuis pietern referenced this pull request in antirez/redis
Closed

Minor issue: va_copy must be matched by va_end #1187

Matt Stancliff mattsta referenced this pull request from a commit in mattsta/redis
Pieter Noordhuis pietern va_copy must be matched by va_end
Hat tip to @rfuchs. See: redis/hiredis#178.

Fixes #1187
90f0afe
Matt Stancliff mattsta referenced this pull request from a commit in mattsta/redis
Pieter Noordhuis pietern va_copy must be matched by va_end
Hat tip to @rfuchs. See: redis/hiredis#178.

Fixes #1187
c3db4f7
Matt Stancliff mattsta referenced this pull request from a commit in mattsta/redis
Pieter Noordhuis pietern va_copy must be matched by va_end
Hat tip to @rfuchs. See: redis/hiredis#178.

Fixes #1187
9e3e5c1
Pieter Noordhuis pietern referenced this pull request from a commit in antirez/redis
Pieter Noordhuis pietern va_copy must be matched by va_end
Hat tip to @rfuchs. See: redis/hiredis#178.

Fixes #1187
cf85b5b
Pieter Noordhuis pietern referenced this pull request from a commit in antirez/redis
Pieter Noordhuis pietern va_copy must be matched by va_end
Hat tip to @rfuchs. See: redis/hiredis#178.

Fixes #1187
327831e
Pieter Noordhuis pietern referenced this pull request from a commit in antirez/redis
Pieter Noordhuis pietern va_copy must be matched by va_end
Hat tip to @rfuchs. See: redis/hiredis#178.

Fixes #1187
f89a7bb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jul 2, 2013
  1. Richard Fuchs
This page is out of date. Refresh to see the latest.
Showing with 1 addition and 0 deletions.
  1. +1 −0  sds.c
1  sds.c
View
@@ -178,6 +178,7 @@ sds sdscatvprintf(sds s, const char *fmt, va_list ap) {
buf[buflen-2] = '\0';
va_copy(cpy,ap);
vsnprintf(buf, buflen, fmt, cpy);
+ va_end(cpy);
if (buf[buflen-2] != '\0') {
free(buf);
buflen *= 2;
Something went wrong with that request. Please try again.