Transactions will be removed from the transaction has when they were committed. Thus is is not necessary to check in the push_data/txend packet processing functions for committed/dropped transactions.
Signed-off-by: Sven Eckelmann sven@narfation.org --- recv.c | 8 -------- 1 file changed, 8 deletions(-)
diff --git a/recv.c b/recv.c index 6878e5e..21ea539 100644 --- a/recv.c +++ b/recv.c @@ -167,10 +167,6 @@ static int finish_alfred_transaction(struct globals *globals, { struct transaction_packet *transaction_packet, *safe;
- /* this transaction was already finished/dropped */ - if (head->finished != 0) - return -1; - /* missing packets -> cleanup everything */ if (head->num_packet == num_packets) head->finished = -1; @@ -233,10 +229,6 @@ static int process_alfred_push_data(struct globals *globals, } clock_gettime(CLOCK_MONOTONIC, &head->last_rx_time);
- /* this transaction was already finished/dropped */ - if (head->finished != 0) - return -1; - found = 0; list_for_each_entry(transaction_packet, &head->packet_list, list) { if (transaction_packet->push->tx.seqno == push->tx.seqno) {