- Fix prematurely terminated TCP queries when a reply has the same ID.

This commit is contained in:
George Thessalonikefs 2022-01-11 10:00:04 +01:00
parent d52d94c6db
commit a97604737b
2 changed files with 9 additions and 0 deletions

View file

@ -1,3 +1,6 @@
11 January 2022: George
- Fix prematurely terminated TCP queries when a reply has the same ID.
7 January 2022: Wouter
- Merge #600 from pemensik: Change file mode before changing file
owner.

View file

@ -1248,6 +1248,12 @@ outnet_tcp_cb(struct comm_point* c, void* arg, int error,
c->buffer));
/* find the query the reply is for */
w = reuse_tcp_by_id_find(&pend->reuse, id);
/* Make sure that the reply we got is at least for a
* sent query with the same ID; the waiting_tcp that
* gets a reply is assumed to not be waiting to be
* sent. */
if(w && (w->on_tcp_waiting_list || w->write_wait_queued))
w = NULL;
}
}
if(error == NETEVENT_NOERROR && !w) {