diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-08-15 21:46:35 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-08-15 21:46:35 +0000 |
commit | 502af2167f7c218366666ca4944bd7cc54b5b19a (patch) | |
tree | a91fec5cc9769d260640bd91c6633cb9cf395524 /src/util/test_crypto_hash.c | |
parent | 03af5a603b7cc53432249d5854cd412aa90dde0d (diff) | |
download | gnunet-502af2167f7c218366666ca4944bd7cc54b5b19a.tar.gz gnunet-502af2167f7c218366666ca4944bd7cc54b5b19a.zip |
indentation
Diffstat (limited to 'src/util/test_crypto_hash.c')
-rw-r--r-- | src/util/test_crypto_hash.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/util/test_crypto_hash.c b/src/util/test_crypto_hash.c index 85de9fbbb..b0fa4f332 100644 --- a/src/util/test_crypto_hash.c +++ b/src/util/test_crypto_hash.c | |||
@@ -42,10 +42,10 @@ test (int number) | |||
42 | memset (&h1, number, sizeof (GNUNET_HashCode)); | 42 | memset (&h1, number, sizeof (GNUNET_HashCode)); |
43 | GNUNET_CRYPTO_hash_to_enc (&h1, &enc); | 43 | GNUNET_CRYPTO_hash_to_enc (&h1, &enc); |
44 | if (GNUNET_OK != GNUNET_CRYPTO_hash_from_string ((char *) &enc, &h2)) | 44 | if (GNUNET_OK != GNUNET_CRYPTO_hash_from_string ((char *) &enc, &h2)) |
45 | { | 45 | { |
46 | printf ("enc2hash failed!\n"); | 46 | printf ("enc2hash failed!\n"); |
47 | return 1; | 47 | return 1; |
48 | } | 48 | } |
49 | if (0 != memcmp (&h1, &h2, sizeof (GNUNET_HashCode))) | 49 | if (0 != memcmp (&h1, &h2, sizeof (GNUNET_HashCode))) |
50 | return 1; | 50 | return 1; |
51 | return 0; | 51 | return 0; |
@@ -55,6 +55,7 @@ static int | |||
55 | testEncoding () | 55 | testEncoding () |
56 | { | 56 | { |
57 | int i; | 57 | int i; |
58 | |||
58 | for (i = 0; i < 255; i++) | 59 | for (i = 0; i < 255; i++) |
59 | if (0 != test (i)) | 60 | if (0 != test (i)) |
60 | return 1; | 61 | return 1; |
@@ -123,9 +124,8 @@ static void | |||
123 | file_hasher (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 124 | file_hasher (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) |
124 | { | 125 | { |
125 | GNUNET_assert (NULL != | 126 | GNUNET_assert (NULL != |
126 | GNUNET_CRYPTO_hash_file (GNUNET_SCHEDULER_PRIORITY_DEFAULT, | 127 | GNUNET_CRYPTO_hash_file (GNUNET_SCHEDULER_PRIORITY_DEFAULT, |
127 | FILENAME, 1024, | 128 | FILENAME, 1024, &finished_task, cls)); |
128 | &finished_task, cls)); | ||
129 | } | 129 | } |
130 | 130 | ||
131 | 131 | ||