[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnunet] branch master updated: - backchannel alternativ 1
From: |
gnunet |
Subject: |
[gnunet] branch master updated: - backchannel alternativ 1 |
Date: |
Thu, 15 Oct 2020 08:44:24 +0200 |
This is an automated email from the git hooks/post-receive script.
t3sserakt pushed a commit to branch master
in repository gnunet.
The following commit(s) were added to refs/heads/master by this push:
new 2c529c700 - backchannel alternativ 1
2c529c700 is described below
commit 2c529c7009239b4c9068069bb63f3978a9a41b1a
Author: t3sserakt <t3ss@posteo.de>
AuthorDate: Thu Oct 15 08:36:32 2020 +0200
- backchannel alternativ 1
---
src/transport/gnunet-communicator-udp.c | 18 +++++++++++-------
src/transport/test_communicator_basic.c | 2 +-
src/transport/transport-testing2.c | 10 ++++++----
3 files changed, 18 insertions(+), 12 deletions(-)
diff --git a/src/transport/gnunet-communicator-udp.c
b/src/transport/gnunet-communicator-udp.c
index 1df79745a..4dc65896e 100644
--- a/src/transport/gnunet-communicator-udp.c
+++ b/src/transport/gnunet-communicator-udp.c
@@ -969,7 +969,8 @@ secret_destroy (struct SharedSecret *ss)
GNUNET_CONTAINER_DLL_remove (receiver->ss_head, receiver->ss_tail, ss);
receiver->num_secrets--;
// Uncomment this for alternativ 1 of backchannel functionality
- // receiver->acks_available -= (ss->sequence_allowed - ss->sequence_used);
+ receiver->acks_available -= (ss->sequence_allowed - ss->sequence_used);
+ // Until here for alternativ 1
}
while (NULL != (kce = ss->kce_head))
kce_destroy (kce);
@@ -1341,14 +1342,15 @@ handle_ack (void *cls, const struct GNUNET_PeerIdentity
*pid, void *value)
ack->acks_available,
GNUNET_h2s (&ss->master));
// Uncomment this for alternativ 1 of backchannel functionality
- /*receiver->acks_available += (allowed - ss->sequence_allowed);
+ receiver->acks_available += (allowed - ss->sequence_allowed);
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Tell transport we have more acks!\n");
GNUNET_TRANSPORT_communicator_mq_update (ch,
receiver->d_qh,
(allowed
- ss->sequence_allowed),
- 1);*/
+ 1);
+ // Until here for alternativ 1
ss->sequence_allowed = allowed;
/* move ss to head to avoid discarding it anytime soon! */
GNUNET_CONTAINER_DLL_remove (receiver->ss_head, receiver->ss_tail, ss);
@@ -1356,7 +1358,7 @@ handle_ack (void *cls, const struct GNUNET_PeerIdentity
*pid, void *value)
}
// Uncomment this for alternativ 2 of backchannel functionality
- if (receiver->acks_available != ack->acks_available)
+ /*if (receiver->acks_available != ack->acks_available)
{
receiver->acks_available = ack->acks_available;
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
@@ -1365,7 +1367,7 @@ handle_ack (void *cls, const struct GNUNET_PeerIdentity
*pid, void *value)
receiver->d_qh,
receiver->acks_available,
1);
- }
+ }*/
// Until here for alternativ 2
return GNUNET_NO;
}
@@ -2198,9 +2200,11 @@ mq_send_d (struct GNUNET_MQ_Handle *mq,
ss->sequence_used,
ss->sequence_allowed);
// Uncomment this for alternativ 1 of backchannel functionality
- // if (ss->sequence_used >= ss->sequence_allowed)
+ if (ss->sequence_used >= ss->sequence_allowed)
+ // Until here for alternativ 1
// Uncomment this for alternativ 2 of backchannel functionality
- if (0 == ss->sequence_allowed)
+ // if (0 == ss->sequence_allowed)
+ // Until here for alternativ 2
{
continue;
}
diff --git a/src/transport/test_communicator_basic.c
b/src/transport/test_communicator_basic.c
index d599d06c6..8251a5169 100644
--- a/src/transport/test_communicator_basic.c
+++ b/src/transport/test_communicator_basic.c
@@ -85,7 +85,7 @@ static unsigned int iterations_left = TOTAL_ITERATIONS;
#define TIMEOUT_MULTIPLIER 1
#define DELAY \
- GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MICROSECONDS,30)
+ GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MICROSECONDS,50)
#define SHORT_BURST_WINDOW \
GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS,2)
diff --git a/src/transport/transport-testing2.c
b/src/transport/transport-testing2.c
index 1e2579048..076fbf331 100644
--- a/src/transport/transport-testing2.c
+++ b/src/transport/transport-testing2.c
@@ -554,9 +554,10 @@ handle_update_queue_message (void *cls,
tc_queue->cs = msg->cs;
tc_queue->priority = ntohl (msg->priority);
// Uncomment this for alternativ 1 of backchannel functionality
- // tc_queue->q_len += GNUNET_ntohll (msg->q_len);
+ tc_queue->q_len += GNUNET_ntohll (msg->q_len);
+ // Until here for alternativ 1
// Uncomment this for alternativ 2 of backchannel functionality
- tc_queue->q_len = GNUNET_ntohll (msg->q_len);
+ // tc_queue->q_len = GNUNET_ntohll (msg->q_len);
// Until here for alternativ 2
GNUNET_SERVICE_client_continue (client->client);
}
@@ -1135,8 +1136,9 @@ GNUNET_TRANSPORT_TESTING_transport_communicator_send
}
GNUNET_assert (NULL != tc_queue);
// Uncomment this for alternativ 1 of backchannel functionality
- /*if (tc_queue->q_len != GNUNET_TRANSPORT_QUEUE_LENGTH_UNLIMITED)
- tc_queue->q_len--;*/
+ if (tc_queue->q_len != GNUNET_TRANSPORT_QUEUE_LENGTH_UNLIMITED)
+ tc_queue->q_len--;
+ // Until here for alternativ 1
GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
"Sending message\n");
inbox_size = sizeof (struct GNUNET_MessageHeader) + payload_size;
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [gnunet] branch master updated: - backchannel alternativ 1,
gnunet <=