From: Marcus Brinkmann Date: Sun, 22 Jun 2003 20:56:48 +0000 (+0000) Subject: 2003-06-22 Marcus Brinkmann X-Git-Tag: gpgme-0-4-2~23 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=83cc539b1d1b9c59af37dcbab7fede40dfc0de63;p=gpgme.git 2003-06-22 Marcus Brinkmann * data-mem.c (mem_write): Copy original buffer content. --- diff --git a/gpgme/ChangeLog b/gpgme/ChangeLog index aa83765..06a2c02 100644 --- a/gpgme/ChangeLog +++ b/gpgme/ChangeLog @@ -1,3 +1,7 @@ +2003-06-22 Marcus Brinkmann + + * data-mem.c (mem_write): Copy original buffer content. + 2003-06-22 Marcus Brinkmann * gpgme.h (gpgme_user_ids_release, gpgme_user_ids_append): Remove diff --git a/gpgme/data-mem.c b/gpgme/data-mem.c index bb6b81d..6d11899 100644 --- a/gpgme/data-mem.c +++ b/gpgme/data-mem.c @@ -66,6 +66,8 @@ mem_write (gpgme_data_t dh, const void *buffer, size_t size) new_buffer = malloc (new_size); if (!new_buffer) return -1; + memcpy (new_buffer, dh->data.mem.orig_buffer, dh->data.mem.length); + dh->data.mem.buffer = new_buffer; dh->data.mem.size = new_size; } diff --git a/gpgme/gpgme.h b/gpgme/gpgme.h index 5dc4ece..42b4ec2 100644 --- a/gpgme/gpgme.h +++ b/gpgme/gpgme.h @@ -63,7 +63,7 @@ extern "C" { AM_PATH_GPGME macro) check that this header matches the installed library. Warning: Do not edit the next line. configure will do that for you! */ -#define GPGME_VERSION "0.4.1" +#define GPGME_VERSION "0.4.2" /* Some opaque data types used by GPGME. */