[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r9242 - GNUnet/src/applications/testing
From: |
gnunet |
Subject: |
[GNUnet-SVN] r9242 - GNUnet/src/applications/testing |
Date: |
Thu, 22 Oct 2009 18:53:54 -0600 |
Author: nevans
Date: 2009-10-22 18:53:54 -0600 (Thu, 22 Oct 2009)
New Revision: 9242
Modified:
GNUnet/src/applications/testing/remote.c
GNUnet/src/applications/testing/remotetopologies.c
GNUnet/src/applications/testing/testing.c
Log:
minor testing changes
Modified: GNUnet/src/applications/testing/remote.c
===================================================================
--- GNUnet/src/applications/testing/remote.c 2009-10-22 20:40:32 UTC (rev
9241)
+++ GNUnet/src/applications/testing/remote.c 2009-10-23 00:53:54 UTC (rev
9242)
@@ -238,12 +238,10 @@
#if VERBOSE
fprintf (stderr, _("exec command is : %s \n"), cmd);
#endif
-
unused = system (cmd);
-
GNUNET_free (cmd);
-
-
+ GNUNET_thread_sleep(500 * GNUNET_CRON_MILLISECONDS);
+ UNLINK (tokill->path);
return GNUNET_OK;
}
@@ -557,7 +555,9 @@
i = 0;
count_started = 0;
modnum = number_of_daemons / 4;
- dotnum = number_of_daemons / 50;
+ dotnum = ceil(number_of_daemons / 50);
+ if (dotnum == 0)
+ dotnum = 1;
pos = length;
fprintf (stdout, "Daemon start progress: [");
fflush (stdout);
@@ -795,6 +795,7 @@
(struct GNUNET_REMOTE_TESTING_DaemonContext));
next_peer->next = new_ret_peers;
next_peer->hostname = GNUNET_strdup (curr_host);
+ next_peer->path = GNUNET_strdup (temp_path);
next_peer->username = GNUNET_strdup (ssh_username);
next_peer->port = starting_port + (j * port_increment);
next_peer->pid = GNUNET_strdup (temp_pid_file);
@@ -1099,6 +1100,7 @@
next_peer->hostname = GNUNET_strdup (curr_host);
next_peer->port =
starting_port + ((j + 1) * port_increment);
+ next_peer->path = GNUNET_strdup (temp_path);
next_peer->username = GNUNET_strdup (ssh_username);
next_peer->pid = GNUNET_strdup (temp_pid_file);
next_peer->malicious_val = malicious_mask;
@@ -1393,9 +1395,13 @@
}
totalCreatedConnections = 0;
totalConnectAttempts = 0;
- modnum = totalConnections / 4;
- dotnum = totalConnections / 50;
+ if (totalConnections < 1)
+ return 0;
+ modnum = ceil(totalConnections / 4);
+ dotnum = ceil(totalConnections / 50);
+ if (dotnum == 0)
+ dotnum = 1;
if (ret == GNUNET_OK)
{
pos = head;
@@ -1475,7 +1481,9 @@
connectFailures = 0;
tempThreadCount = 0;
modnum = number_of_daemons / 4;
- dotnum = number_of_daemons / 50;
+ dotnum = ceil(number_of_daemons / 50);
+ if (dotnum == 0)
+ dotnum = 1;
fprintf (stdout, "Friend connection progress: \[");
for (j = 0; j < number_of_daemons; j++)
{
Modified: GNUnet/src/applications/testing/remotetopologies.c
===================================================================
--- GNUnet/src/applications/testing/remotetopologies.c 2009-10-22 20:40:32 UTC
(rev 9241)
+++ GNUnet/src/applications/testing/remotetopologies.c 2009-10-23 00:53:54 UTC
(rev 9242)
@@ -222,11 +222,11 @@
while (pos->next != NULL)
{
iter_pos = pos->next;
- addNodeRefs (pos, iter_pos);
+ (*totalConnections) += addNodeRefs (pos, iter_pos);
pos = pos->next;
}
iter_pos = main_list;
- addNodeRefs (pos, iter_pos);
+ (*totalConnections) += addNodeRefs (pos, iter_pos);
return GNUNET_OK;
}
Modified: GNUnet/src/applications/testing/testing.c
===================================================================
--- GNUnet/src/applications/testing/testing.c 2009-10-22 20:40:32 UTC (rev
9241)
+++ GNUnet/src/applications/testing/testing.c 2009-10-23 00:53:54 UTC (rev
9242)
@@ -177,7 +177,7 @@
{
fprintf (stderr, "Failed to confirm daemon running!\n");
GNUNET_GC_free (cfg);
- UNLINK (dpath);
+ //UNLINK (dpath);
GNUNET_free (dpath);
return GNUNET_SYSERR;
}
@@ -416,7 +416,7 @@
next = peers->next;
if (GNUNET_OK != GNUNET_TESTING_stop_daemon (peers->port, peers->pid))
ret = GNUNET_SYSERR;
- UNLINK (peers->configFile);
+ //UNLINK (peers->configFile);
GNUNET_free (peers->configFile);
GNUNET_free (peers);
peers = next;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r9242 - GNUnet/src/applications/testing,
gnunet <=