summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMoritz Schulte <mo@g10code.com>2003-07-08 18:58:41 +0000
committerMoritz Schulte <mo@g10code.com>2003-07-08 18:58:41 +0000
commite33916bc37b5c78771b88acbb12ae5056c9685e5 (patch)
treee94d3493cd4ec6ddb1caf4046521cc156c2f6140 /tests
parent4bd6fcd68e120a0f164fc7269ea220c84a1faf1b (diff)
downloadlibgcrypt-e33916bc37b5c78771b88acbb12ae5056c9685e5.tar.gz
Improve.
Diffstat (limited to 'tests')
-rw-r--r--tests/ac.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/ac.c b/tests/ac.c
index efb955a8..a3532cdc 100644
--- a/tests/ac.c
+++ b/tests/ac.c
@@ -48,7 +48,7 @@ check_run (void)
gpg_error_t err = 0;
unsigned int a = 0x4223;
gcry_mpi_t x, x2;
- gcry_ac_data_t data;
+ gcry_ac_data_t data, data2;
gcry_ac_key_spec_rsa_t rsa_spec;
rsa_spec.e = gcry_mpi_new (0);
@@ -80,6 +80,13 @@ check_run (void)
err = gcry_ac_data_sign (handle, key_sec, x, &data);
assert (! err);
+ err = gcry_ac_data_copy (&data2, data);
+ assert (! err);
+ gcry_ac_data_destroy (data);
+ err = gcry_ac_data_copy (&data, data2);
+ assert (! err);
+ gcry_ac_data_destroy (data2);
+
err = gcry_ac_data_verify (handle, key_pub, x, data);
assert (! err);