diff options
author | Christian Grothoff <christian@grothoff.org> | 2014-12-18 16:22:14 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2014-12-18 16:22:14 +0000 |
commit | fb12af8319a84389a536ab2f3735daf3b24f11bd (patch) | |
tree | 53e1424149fe8e7d5673e783868fcaa8a6bdbb55 /src/peerstore/test_peerstore_api_store.c | |
parent | d19064a18f3fcf35c94d7f56485e41fb3425d066 (diff) | |
download | gnunet-fb12af8319a84389a536ab2f3735daf3b24f11bd.tar.gz gnunet-fb12af8319a84389a536ab2f3735daf3b24f11bd.zip |
-use const in peerstore callback
Diffstat (limited to 'src/peerstore/test_peerstore_api_store.c')
-rw-r--r-- | src/peerstore/test_peerstore_api_store.c | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/src/peerstore/test_peerstore_api_store.c b/src/peerstore/test_peerstore_api_store.c index 06ad34756..794a2b048 100644 --- a/src/peerstore/test_peerstore_api_store.c +++ b/src/peerstore/test_peerstore_api_store.c | |||
@@ -37,10 +37,12 @@ static char *val1 = "test_peerstore_api_store_val1"; | |||
37 | static char *val2 = "test_peerstore_api_store_val2-"; | 37 | static char *val2 = "test_peerstore_api_store_val2-"; |
38 | static char *val3 = "test_peerstore_api_store_val3--"; | 38 | static char *val3 = "test_peerstore_api_store_val3--"; |
39 | 39 | ||
40 | int count = 0; | 40 | static int count = 0; |
41 | 41 | ||
42 | int | 42 | static int |
43 | test3_cont2 (void *cls, struct GNUNET_PEERSTORE_Record *record, char *emsg) | 43 | test3_cont2 (void *cls, |
44 | const struct GNUNET_PEERSTORE_Record *record, | ||
45 | const char *emsg) | ||
44 | { | 46 | { |
45 | if (NULL != emsg) | 47 | if (NULL != emsg) |
46 | return GNUNET_NO; | 48 | return GNUNET_NO; |
@@ -83,8 +85,10 @@ test3 () | |||
83 | } | 85 | } |
84 | 86 | ||
85 | 87 | ||
86 | int | 88 | static int |
87 | test2_cont2 (void *cls, struct GNUNET_PEERSTORE_Record *record, char *emsg) | 89 | test2_cont2 (void *cls, |
90 | const struct GNUNET_PEERSTORE_Record *record, | ||
91 | const char *emsg) | ||
88 | { | 92 | { |
89 | if (NULL != emsg) | 93 | if (NULL != emsg) |
90 | return GNUNET_NO; | 94 | return GNUNET_NO; |
@@ -128,8 +132,10 @@ test2 () | |||
128 | } | 132 | } |
129 | 133 | ||
130 | 134 | ||
131 | int | 135 | static int |
132 | test1_cont2 (void *cls, struct GNUNET_PEERSTORE_Record *record, char *emsg) | 136 | test1_cont2 (void *cls, |
137 | const struct GNUNET_PEERSTORE_Record *record, | ||
138 | const char *emsg) | ||
133 | { | 139 | { |
134 | if (NULL != emsg) | 140 | if (NULL != emsg) |
135 | return GNUNET_NO; | 141 | return GNUNET_NO; |
@@ -172,7 +178,8 @@ test1 () | |||
172 | 178 | ||
173 | 179 | ||
174 | static void | 180 | static void |
175 | run (void *cls, const struct GNUNET_CONFIGURATION_Handle *cfg, | 181 | run (void *cls, |
182 | const struct GNUNET_CONFIGURATION_Handle *cfg, | ||
176 | struct GNUNET_TESTING_Peer *peer) | 183 | struct GNUNET_TESTING_Peer *peer) |
177 | { | 184 | { |
178 | h = GNUNET_PEERSTORE_connect (cfg); | 185 | h = GNUNET_PEERSTORE_connect (cfg); |