This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Tarantool -- an efficient key/value data store".
The branch core-config-reread has been updated
via ae98f82feff9d9686a1b3a7cc8691be6e1a9d497 (commit)
from b284590c20f3600e1b3cd6293281b1b092691642 (commit)
Summary of changes:
core/tbuf.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
commit ae98f82feff9d9686a1b3a7cc8691be6e1a9d497
Author: Roman Tokarev <[email protected]>
Date: Wed Dec 1 13:14:14 2010 +0300
[core] fix tbuf_vprintf
diff --git a/core/tbuf.c b/core/tbuf.c
index c7f3037..92ad5fb 100644
--- a/core/tbuf.c
+++ b/core/tbuf.c
@@ -155,6 +155,9 @@ void tbuf_vprintf(struct tbuf *b, const char *format,
va_list ap)
{
int printed_len;
size_t free_len = b->size - b->len;
+ va_list ap_copy;
+
+ va_copy(ap_copy, ap);
tbuf_assert(b);
printed_len = vsnprintf(((char *)b->data) + b->len, free_len, format,
ap);
@@ -166,7 +169,7 @@ void tbuf_vprintf(struct tbuf *b, const char *format,
va_list ap)
if (free_len <= printed_len) {
tbuf_ensure(b, printed_len + 1);
free_len = b->size - b->len - 1;
- printed_len = vsnprintf(((char *)b->data) + b->len, free_len,
format, ap);
+ printed_len = vsnprintf(((char *)b->data) + b->len, free_len,
format, ap_copy);
}
b->len += printed_len;
--
Tarantool -- an efficient key/value data store
_______________________________________________
Mailing list: https://launchpad.net/~tarantool-developers
Post to : [email protected]
Unsubscribe : https://launchpad.net/~tarantool-developers
More help : https://help.launchpad.net/ListHelp