--- /dev/null
+--- rpm-4.0.2/rpmio/rpmlog.c.orig Thu Jul 25 15:53:07 2002
++++ rpm-4.0.2/rpmio/rpmlog.c Thu Jul 25 16:02:25 2002
+@@ -7,6 +7,18 @@
+ #include "rpmlog.h"
+ #include "debug.h"
+
++#ifndef va_copy
++# ifdef __va_copy
++# define va_copy(DEST,SRC) __va_copy((DEST),(SRC))
++# else
++# ifdef HAVE_VA_LIST_AS_ARRAY
++# define va_copy(DEST,SRC) (*(DEST) = *(SRC))
++# else
++# define va_copy(DEST,SRC) ((DEST) = (SRC))
++# endif
++# endif
++#endif
++
+ /*@access rpmlogRec @*/
+
+ static int nrecs = 0;
+@@ -116,9 +116,9 @@
+
+ /* Allocate a sufficently large buffer for output. */
+ while (1) {
+- /*@-unrecog@*/
+- nb = vsnprintf(msgbuf, msgnb, fmt, ap);
+- /*@=unrecog@*/
++ va_list apc;
++ /*@-sysunrecog -usedef@*/ va_copy(apc, ap); /*@=sysunrecog =usedef@*/
++ nb = vsnprintf(msgbuf, msgnb, fmt, apc);
+ if (nb > -1 && nb < msgnb)
+ break;
+ if (nb > -1) /* glibc 2.1 */