summaryrefslogtreecommitdiff
path: root/lib/compat
diff options
context:
space:
mode:
authorGuillem Jover <guillem@debian.org>2009-09-29 13:47:46 +0200
committerGuillem Jover <guillem@debian.org>2009-09-30 21:39:06 +0200
commit7e8415be3f31884f3fb2c99ef9255344b67bec21 (patch)
tree3e192f53a1ca96da1f51aaad525ca1ec2d525bb0 /lib/compat
parenta31d6e1c1b8438a0ec968c05c58a690eb9023f1d (diff)
downloaddpkg-7e8415be3f31884f3fb2c99ef9255344b67bec21.tar.gz
build: Use memcpy instead of assignment to copy va_list
It's more portable that way. Remove now unneeded check for working assignment.
Diffstat (limited to 'lib/compat')
-rw-r--r--lib/compat/compat.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/compat/compat.h b/lib/compat/compat.h
index 3af717d1a..7e99d05e0 100644
--- a/lib/compat/compat.h
+++ b/lib/compat/compat.h
@@ -44,7 +44,8 @@ extern "C" {
#endif
#ifndef HAVE_VA_COPY
-#define va_copy(dest, src) (dest) = (src)
+#include <string.h>
+#define va_copy(dest, src) memcpy(&(dest), &(src), sizeof(va_list))
#endif
#include <strnlen.h>