diff options
Diffstat (limited to 'src/regex/gnunet-daemon-regexprofiler.c')
-rw-r--r-- | src/regex/gnunet-daemon-regexprofiler.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/regex/gnunet-daemon-regexprofiler.c b/src/regex/gnunet-daemon-regexprofiler.c index a23336808..fb061acc1 100644 --- a/src/regex/gnunet-daemon-regexprofiler.c +++ b/src/regex/gnunet-daemon-regexprofiler.c | |||
@@ -101,7 +101,6 @@ static unsigned int rounds = 3; | |||
101 | static struct GNUNET_CRYPTO_EddsaPrivateKey *my_private_key; | 101 | static struct GNUNET_CRYPTO_EddsaPrivateKey *my_private_key; |
102 | 102 | ||
103 | 103 | ||
104 | |||
105 | /** | 104 | /** |
106 | * Task run during shutdown. | 105 | * Task run during shutdown. |
107 | * | 106 | * |
@@ -157,7 +156,7 @@ reannounce_regex (void *cls) | |||
157 | } | 156 | } |
158 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Announcing regex: %s\n", regex); | 157 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Announcing regex: %s\n", regex); |
159 | GNUNET_STATISTICS_update (stats_handle, "# regexes announced", 1, GNUNET_NO); | 158 | GNUNET_STATISTICS_update (stats_handle, "# regexes announced", 1, GNUNET_NO); |
160 | if ((NULL == announce_handle)&&(NULL != regex)) | 159 | if ((NULL == announce_handle) && (NULL != regex)) |
161 | { | 160 | { |
162 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 161 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
163 | "First time, creating regex: %s\n", | 162 | "First time, creating regex: %s\n", |
@@ -196,7 +195,7 @@ announce_regex (const char *regex) | |||
196 | { | 195 | { |
197 | char *copy; | 196 | char *copy; |
198 | 197 | ||
199 | if ((NULL == regex)||(0 == strlen (regex))) | 198 | if ((NULL == regex) || (0 == strlen (regex))) |
200 | { | 199 | { |
201 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Cannot announce empty regex\n"); | 200 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Cannot announce empty regex\n"); |
202 | return; | 201 | return; |
@@ -393,12 +392,15 @@ main (int argc, char *const *argv) | |||
393 | /** | 392 | /** |
394 | * MINIMIZE heap size (way below 128k) since this process doesn't need much. | 393 | * MINIMIZE heap size (way below 128k) since this process doesn't need much. |
395 | */ | 394 | */ |
396 | void __attribute__ ((constructor)) GNUNET_ARM_memory_init () | 395 | void __attribute__ ((constructor)) |
396 | GNUNET_ARM_memory_init () | ||
397 | { | 397 | { |
398 | mallopt (M_TRIM_THRESHOLD, 4 * 1024); | 398 | mallopt (M_TRIM_THRESHOLD, 4 * 1024); |
399 | mallopt (M_TOP_PAD, 1 * 1024); | 399 | mallopt (M_TOP_PAD, 1 * 1024); |
400 | malloc_trim (0); | 400 | malloc_trim (0); |
401 | } | 401 | } |
402 | |||
403 | |||
402 | #endif | 404 | #endif |
403 | 405 | ||
404 | 406 | ||