aboutsummaryrefslogtreecommitdiff
path: root/src/util/test_crypto_rsa.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2009-11-01 20:47:52 +0000
committerChristian Grothoff <christian@grothoff.org>2009-11-01 20:47:52 +0000
commit652e89b59ed2207c2c12172fdabcd6e659995c81 (patch)
treef054c819d483c1056e18c1099afd4c7fcd2582a0 /src/util/test_crypto_rsa.c
parent5e4113e83368849500792e57946c3d8dd9e548d8 (diff)
downloadgnunet-652e89b59ed2207c2c12172fdabcd6e659995c81.tar.gz
gnunet-652e89b59ed2207c2c12172fdabcd6e659995c81.zip
fixing bio testcase and a bug in bio.c, also indenting
Diffstat (limited to 'src/util/test_crypto_rsa.c')
-rw-r--r--src/util/test_crypto_rsa.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/util/test_crypto_rsa.c b/src/util/test_crypto_rsa.c
index 6b17b4f49..b3663662e 100644
--- a/src/util/test_crypto_rsa.c
+++ b/src/util/test_crypto_rsa.c
@@ -76,9 +76,7 @@ testEncryptDecrypt ()
76 if (strncmp (TESTSTRING, result, strlen (TESTSTRING)) != 0) 76 if (strncmp (TESTSTRING, result, strlen (TESTSTRING)) != 0)
77 { 77 {
78 printf ("%s != %.*s - testEncryptDecrypt failed!\n", 78 printf ("%s != %.*s - testEncryptDecrypt failed!\n",
79 TESTSTRING, 79 TESTSTRING, (int) MAX_TESTVAL, result);
80 (int) MAX_TESTVAL,
81 result);
82 ok++; 80 ok++;
83 continue; 81 continue;
84 } 82 }
@@ -229,8 +227,8 @@ testSignVerify ()
229 continue; 227 continue;
230 } 228 }
231 if (GNUNET_SYSERR != 229 if (GNUNET_SYSERR !=
232 GNUNET_CRYPTO_rsa_verify (GNUNET_SIGNATURE_PURPOSE_TRANSPORT_TCP_PING, 230 GNUNET_CRYPTO_rsa_verify
233 &purp, &sig, &pkey)) 231 (GNUNET_SIGNATURE_PURPOSE_TRANSPORT_TCP_PING, &purp, &sig, &pkey))
234 { 232 {
235 printf ("GNUNET_CRYPTO_rsa_verify failed to fail!\n"); 233 printf ("GNUNET_CRYPTO_rsa_verify failed to fail!\n");
236 ok = GNUNET_SYSERR; 234 ok = GNUNET_SYSERR;
@@ -275,7 +273,8 @@ testSignPerformance ()
275 } 273 }
276 } 274 }
277 printf ("%d RSA sign operations %llu ms\n", ITER, 275 printf ("%d RSA sign operations %llu ms\n", ITER,
278 (unsigned long long) GNUNET_TIME_absolute_get_duration (start).value); 276 (unsigned long long) GNUNET_TIME_absolute_get_duration (start).
277 value);
279 GNUNET_CRYPTO_rsa_key_free (hostkey); 278 GNUNET_CRYPTO_rsa_key_free (hostkey);
280 return ok; 279 return ok;
281} 280}