check return values
authorChristian Grothoff <christian@grothoff.org>
Mon, 24 Oct 2011 11:24:39 +0000 (11:24 +0000)
committerChristian Grothoff <christian@grothoff.org>
Mon, 24 Oct 2011 11:24:39 +0000 (11:24 +0000)
src/transport/test_quota_compliance.c
src/transport/test_transport_api_disconnect.c

index 84d6733ec4768f0ea9e3fe6bae0e454de15cc31f..1c6bba0d5f6decf854e20a4d69e323f825d20b1b 100644 (file)
@@ -468,7 +468,7 @@ generate_config (char * cfg_file,  unsigned long long  quota_in,  unsigned long
 {
   char * fname = NULL;
   struct GNUNET_CONFIGURATION_Handle *cfg = GNUNET_CONFIGURATION_create();
-  GNUNET_CONFIGURATION_load (cfg, cfg_file);
+  GNUNET_assert (GNUNET_OK == GNUNET_CONFIGURATION_load (cfg, cfg_file));
   GNUNET_asprintf (&fname, "q_in_%llu_q_out_%llu_%s", quota_in, quota_out, cfg_file);
   GNUNET_CONFIGURATION_set_value_string(cfg, "PATHS", "DEFAULTCONFIG", fname);
   GNUNET_CONFIGURATION_set_value_number(cfg, "core", "TOTAL_QUOTA_OUT", quota_out);
index 227b0afad81b460a3ee6c54fad7845e27c196d86..850244810128b47baf24c7fdf7b867532ca05907 100644 (file)
@@ -277,8 +277,9 @@ setup_peer (struct PeerContext *p, const char *cfgname)
 
   GNUNET_assert (GNUNET_OK == GNUNET_CONFIGURATION_load (p->cfg, cfgname));
   if (GNUNET_CONFIGURATION_have_value (p->cfg, "PATHS", "SERVICEHOME"))
-    GNUNET_CONFIGURATION_get_value_string (p->cfg, "PATHS", "SERVICEHOME",
-                                           &p->servicehome);
+    GNUNET_assert (GNUNET_OK ==
+                  GNUNET_CONFIGURATION_get_value_string (p->cfg, "PATHS", "SERVICEHOME",
+                                                         &p->servicehome));
   if (NULL != p->servicehome)
     GNUNET_DISK_directory_remove (p->servicehome);