From 3662d75fa3a2cbe52fd9008754b1b6222342308d Mon Sep 17 00:00:00 2001 From: Dimitri Staessens Date: Wed, 20 Sep 2023 12:45:37 +0200 Subject: ipcpd: Broadcast destruction of DHT requests When a request is cancelled/destroyed, all blocking threads should exit. Noticed some hangs on the DHT, this seems to fix/reduce it. Signed-off-by: Dimitri Staessens Signed-off-by: Sander Vrijders --- src/ipcpd/unicast/dir/dht.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/ipcpd/unicast/dir') diff --git a/src/ipcpd/unicast/dir/dht.c b/src/ipcpd/unicast/dir/dht.c index 7e4bd474..5b313e1f 100644 --- a/src/ipcpd/unicast/dir/dht.c +++ b/src/ipcpd/unicast/dir/dht.c @@ -449,7 +449,7 @@ static void kad_req_destroy(struct kad_req * req) return; case REQ_PENDING: req->state = REQ_DESTROY; - pthread_cond_signal(&req->cond); + pthread_cond_broadcast(&req->cond); break; case REQ_INIT: case REQ_DONE: -- cgit v1.2.3