diff options
author | Julius Bünger <buenger@mytum.de> | 2018-07-11 17:32:58 +0200 |
---|---|---|
committer | Julius Bünger <buenger@mytum.de> | 2018-07-11 17:32:58 +0200 |
commit | 08159b18571f395aace0cfa11562517109900305 (patch) | |
tree | 419f86d0d9eb65d8b3236dff9bf266a316550170 /src | |
parent | efc0c09784d55ea347e6208dece55593241f2346 (diff) | |
download | gnunet-08159b18571f395aace0cfa11562517109900305.tar.gz gnunet-08159b18571f395aace0cfa11562517109900305.zip |
fix rps profiler: clean data structure in time
Diffstat (limited to 'src')
-rw-r--r-- | src/rps/gnunet-rps-profiler.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/rps/gnunet-rps-profiler.c b/src/rps/gnunet-rps-profiler.c index a1728cccf..02259d628 100644 --- a/src/rps/gnunet-rps-profiler.c +++ b/src/rps/gnunet-rps-profiler.c | |||
@@ -1353,13 +1353,13 @@ request_peers (void *cls) | |||
1353 | struct RPSPeer *rps_peer; | 1353 | struct RPSPeer *rps_peer; |
1354 | struct PendingReply *pending_rep; | 1354 | struct PendingReply *pending_rep; |
1355 | 1355 | ||
1356 | if (GNUNET_YES == in_shutdown || GNUNET_YES == post_test) | ||
1357 | return; | ||
1358 | rps_peer = pending_req->rps_peer; | 1356 | rps_peer = pending_req->rps_peer; |
1359 | GNUNET_assert (1 <= rps_peer->num_pending_reqs); | 1357 | GNUNET_assert (1 <= rps_peer->num_pending_reqs); |
1360 | GNUNET_CONTAINER_DLL_remove (rps_peer->pending_req_head, | 1358 | GNUNET_CONTAINER_DLL_remove (rps_peer->pending_req_head, |
1361 | rps_peer->pending_req_tail, | 1359 | rps_peer->pending_req_tail, |
1362 | pending_req); | 1360 | pending_req); |
1361 | rps_peer->num_pending_reqs--; | ||
1362 | if (GNUNET_YES == in_shutdown || GNUNET_YES == post_test) return; | ||
1363 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1363 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1364 | "Requesting one peer\n"); | 1364 | "Requesting one peer\n"); |
1365 | pending_rep = GNUNET_new (struct PendingReply); | 1365 | pending_rep = GNUNET_new (struct PendingReply); |
@@ -1372,7 +1372,6 @@ request_peers (void *cls) | |||
1372 | rps_peer->pending_rep_tail, | 1372 | rps_peer->pending_rep_tail, |
1373 | pending_rep); | 1373 | pending_rep); |
1374 | rps_peer->num_pending_reps++; | 1374 | rps_peer->num_pending_reps++; |
1375 | rps_peer->num_pending_reqs--; | ||
1376 | } | 1375 | } |
1377 | 1376 | ||
1378 | 1377 | ||