aboutsummaryrefslogtreecommitdiff
path: root/src/testbed/testbed_api_testbed.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/testbed/testbed_api_testbed.c')
-rw-r--r--src/testbed/testbed_api_testbed.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/testbed/testbed_api_testbed.c b/src/testbed/testbed_api_testbed.c
index a2f60c8cc..d57c3bf4c 100644
--- a/src/testbed/testbed_api_testbed.c
+++ b/src/testbed/testbed_api_testbed.c
@@ -1049,10 +1049,12 @@ GNUNET_TESTBED_run (const char *host_filename,
1049 1049
1050 GNUNET_assert (num_peers > 0); 1050 GNUNET_assert (num_peers > 0);
1051 rc = GNUNET_malloc (sizeof (struct RunContext)); 1051 rc = GNUNET_malloc (sizeof (struct RunContext));
1052 rc->cfg = GNUNET_CONFIGURATION_dup (cfg);
1052 if (NULL != host_filename) 1053 if (NULL != host_filename)
1053 { 1054 {
1054 rc->num_hosts = 1055 rc->num_hosts =
1055 GNUNET_TESTBED_hosts_load_from_file (host_filename, &rc->hosts); 1056 GNUNET_TESTBED_hosts_load_from_file (host_filename, rc->cfg,
1057 &rc->hosts);
1056 if (0 == rc->num_hosts) 1058 if (0 == rc->num_hosts)
1057 { 1059 {
1058 LOG (GNUNET_ERROR_TYPE_WARNING, 1060 LOG (GNUNET_ERROR_TYPE_WARNING,
@@ -1061,8 +1063,7 @@ GNUNET_TESTBED_run (const char *host_filename,
1061 } 1063 }
1062 } 1064 }
1063 else 1065 else
1064 rc->h = GNUNET_TESTBED_host_create (NULL, NULL, 0); 1066 rc->h = GNUNET_TESTBED_host_create (NULL, NULL, rc->cfg, 0);
1065 rc->cfg = GNUNET_CONFIGURATION_dup (cfg);
1066 rc->num_peers = num_peers; 1067 rc->num_peers = num_peers;
1067 rc->event_mask = event_mask; 1068 rc->event_mask = event_mask;
1068 rc->cc = cc; 1069 rc->cc = cc;