Mercurial > pidgin
changeset 2544:271011bbe14e
[gaim-migrate @ 2557]
fine.
committer: Tailor Script <tailor@pidgin.im>
author | Eric Warmenhoven <eric@warmenhoven.org> |
---|---|
date | Fri, 19 Oct 2001 02:43:18 +0000 |
parents | 830a83209475 |
children | ac6f0a173055 |
files | src/core.c |
diffstat | 1 files changed, 4 insertions(+), 9 deletions(-) [+] |
line wrap: on
line diff
--- a/src/core.c Thu Oct 18 22:36:47 2001 +0000 +++ b/src/core.c Fri Oct 19 02:43:18 2001 +0000 @@ -41,16 +41,13 @@ static gint UI_fd = -1; GSList *uis = NULL; -static guchar *UI_build(guint32 *len, guchar type, guchar subtype, va_list args1) +static guchar *UI_build(guint32 *len, guchar type, guchar subtype, va_list args) { - va_list args2; guchar *buffer; guint32 pos; int size; void *data; - G_VA_COPY(args2, args1); - *len = sizeof(guchar) * 2 + 4; buffer = g_malloc(*len); pos = 0; @@ -61,16 +58,16 @@ /* we come back and do size last */ pos += 4; - size = va_arg(args2, int); + size = va_arg(args, int); while (size != -1) { *len += size; buffer = g_realloc(buffer, *len); - data = va_arg(args2, void *); + data = va_arg(args, void *); memcpy(buffer + pos, data, size); pos += size; - size = va_arg(args2, int); + size = va_arg(args, int); } pos -= sizeof(guchar) * 2 + 4; @@ -78,8 +75,6 @@ /* now we do size */ memcpy(buffer + sizeof(guchar) * 2, &pos, 4); - va_end(args2); - return buffer; }