From e6939db6d6074c941acc52ad6bc3b1db97c2071b Mon Sep 17 00:00:00 2001 From: Christos Zoulas Date: Thu, 17 Apr 2014 12:45:50 +0000 Subject: [PATCH] try to fix memcpy (Jean-Louis CHARTON) --- src/vasprintf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vasprintf.c b/src/vasprintf.c index 5630a160..8ea7b99a 100644 --- a/src/vasprintf.c +++ b/src/vasprintf.c @@ -108,7 +108,7 @@ you use strange formats. #include "file.h" #ifndef lint -FILE_RCSID("@(#)$File: vasprintf.c,v 1.9 2012/08/09 16:33:30 christos Exp $") +FILE_RCSID("@(#)$File: vasprintf.c,v 1.10 2012/08/09 16:40:04 christos Exp $") #endif /* lint */ #include @@ -639,7 +639,7 @@ int vasprintf(char **ptr, const char *format_string, va_list vargs) #ifdef __va_copy __va_copy (s.vargs, vargs); #else - memcpy (&s.vargs, vargs, sizeof (va_list)); + memcpy (&s.vargs, &vargs, sizeof (s.va_args)); #endif /* __va_copy */ #endif /* va_copy */ s.maxlen = (size_t)INT_MAX; -- 2.40.0