aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-01-30 13:26:11 +0000
committerChristian Grothoff <christian@grothoff.org>2012-01-30 13:26:11 +0000
commitd6f6be87c98362faa95a84d27a65b79694369fee (patch)
treedb8750543f4ae73c89f7ffbca75a3d5d435f0fe1
parent91b1aa807cc9cda1dc109bdc8760ff3a4540cab5 (diff)
downloadgnunet-d6f6be87c98362faa95a84d27a65b79694369fee.tar.gz
gnunet-d6f6be87c98362faa95a84d27a65b79694369fee.zip
-trying to fix double-start issue on sparc
-rw-r--r--src/arm/gnunet-service-arm.c10
-rw-r--r--src/util/configuration.c4
2 files changed, 11 insertions, 3 deletions
diff --git a/src/arm/gnunet-service-arm.c b/src/arm/gnunet-service-arm.c
index 88fabef2f..064cb9777 100644
--- a/src/arm/gnunet-service-arm.c
+++ b/src/arm/gnunet-service-arm.c
@@ -308,6 +308,7 @@ start_process (struct ServiceList *sl)
308 "Starting service `%s' using binary `%s' and configuration `%s'\n", 308 "Starting service `%s' using binary `%s' and configuration `%s'\n",
309 sl->name, sl->binary, sl->config); 309 sl->name, sl->binary, sl->config);
310#endif 310#endif
311 GNUNET_assert (NULL == sl->proc);
311 if (GNUNET_YES == use_debug) 312 if (GNUNET_YES == use_debug)
312 sl->proc = 313 sl->proc =
313 do_start_process (lsocks, loprefix, sl->binary, "-c", sl->config, "-L", 314 do_start_process (lsocks, loprefix, sl->binary, "-c", sl->config, "-L",
@@ -407,7 +408,7 @@ find_service (const char *name)
407 sl = running_head; 408 sl = running_head;
408 while (sl != NULL) 409 while (sl != NULL)
409 { 410 {
410 if (0 == strcmp (sl->name, name)) 411 if (0 == strcasecmp (sl->name, name))
411 return sl; 412 return sl;
412 sl = sl->next; 413 sl = sl->next;
413 } 414 }
@@ -1041,6 +1042,13 @@ setup_service (void *cls, const char *section)
1041 /* not a service section */ 1042 /* not a service section */
1042 return; 1043 return;
1043 } 1044 }
1045 sl = find_service (section);
1046 if (NULL != sl)
1047 {
1048 /* got the same section twice!? */
1049 GNUNET_break (0);
1050 return;
1051 }
1044 config = NULL; 1052 config = NULL;
1045 if ((GNUNET_OK != 1053 if ((GNUNET_OK !=
1046 GNUNET_CONFIGURATION_get_value_filename (cfg, section, "CONFIG", 1054 GNUNET_CONFIGURATION_get_value_filename (cfg, section, "CONFIG",
diff --git a/src/util/configuration.c b/src/util/configuration.c
index 50f32e286..f24b2c2c6 100644
--- a/src/util/configuration.c
+++ b/src/util/configuration.c
@@ -407,7 +407,7 @@ GNUNET_CONFIGURATION_iterate_section_values (const struct
407 struct ConfigEntry *epos; 407 struct ConfigEntry *epos;
408 408
409 spos = cfg->sections; 409 spos = cfg->sections;
410 while ((spos != NULL) && (0 != strcmp (spos->name, section))) 410 while ((spos != NULL) && (0 != strcasecmp (spos->name, section)))
411 spos = spos->next; 411 spos = spos->next;
412 412
413 if (spos == NULL) 413 if (spos == NULL)
@@ -465,7 +465,7 @@ GNUNET_CONFIGURATION_remove_section (struct GNUNET_CONFIGURATION_Handle *cfg,
465 spos = cfg->sections; 465 spos = cfg->sections;
466 while (spos != NULL) 466 while (spos != NULL)
467 { 467 {
468 if (0 == strcmp (section, spos->name)) 468 if (0 == strcasecmp (section, spos->name))
469 { 469 {
470 if (prev == NULL) 470 if (prev == NULL)
471 cfg->sections = spos->next; 471 cfg->sections = spos->next;