+2002-08-29 Marcus Brinkmann <marcus@g10code.de>
+
+ * passphrase.c (_gpgme_passphrase_status_handler): Reset
+ CTX->result.passphrase->no_passphrase if passphrase is given (good
+ or bad). Submitted by Jean DIRAISON <jean.diraison@free.fr>.
+
2002-08-28 Marcus Brinkmann <marcus@g10code.de>
* posix-io.c (_gpgme_io_spawn): Use a double-fork approach.
case GPGME_STATUS_BAD_PASSPHRASE:
ctx->result.passphrase->bad_passphrase++;
+ ctx->result.passphrase->no_passphrase = 0;
break;
case GPGME_STATUS_GOOD_PASSPHRASE:
ctx->result.passphrase->bad_passphrase = 0;
+ ctx->result.passphrase->no_passphrase = 0;
break;
case GPGME_STATUS_NEED_PASSPHRASE:
#include <stdlib.h>
#include <stdarg.h>
+
+#ifndef va_copy
+#if defined (__GNUC__) && defined (__PPC__) \
+ && (defined (_CALL_SYSV) || defined (_WIN32))
+#define va_copy(d, s) (*(d) = *(s))
+#elif defined (MUST_COPY_VA_BYVAL)
+#define va_copy(d, s) ((d) = (s))
+#else
+#define va_copy(d, s) memcpy ((d), (s), sizeof (va_list))
+#endif
+#endif
+
+
#ifdef TEST
int global_total_width;
#endif
int total_width = strlen (format) + 1;
va_list ap;
- /* FIXME: use va_copy() */
- memcpy (&ap, args, sizeof (va_list));
+ va_copy (ap, *args);
while (*p != '\0')
{