summaryrefslogtreecommitdiff
path: root/libcr_ipc
diff options
context:
space:
mode:
authorLuke T. Shumaker <lukeshu@lukeshu.com>2025-01-11 23:33:44 -0700
committerLuke T. Shumaker <lukeshu@lukeshu.com>2025-01-11 23:33:44 -0700
commit7eda822ef31a15d22de03fc1eec7d995f661b26d (patch)
tree0f00fdf307cfa78337c50a43e2ff842942922af5 /libcr_ipc
parent8573ec62fe175edc73c6c54d24e520ee6aba3f96 (diff)
parentd29cb3f3deda2ae55fbccfdaae3b2481410a0894 (diff)
Merge branch 'lukeshu/9p-tests'
Diffstat (limited to 'libcr_ipc')
-rw-r--r--libcr_ipc/include/libcr_ipc/rpc.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/libcr_ipc/include/libcr_ipc/rpc.h b/libcr_ipc/include/libcr_ipc/rpc.h
index 0d6d25e..80eee74 100644
--- a/libcr_ipc/include/libcr_ipc/rpc.h
+++ b/libcr_ipc/include/libcr_ipc/rpc.h
@@ -1,6 +1,6 @@
/* libcr_ipc/rpc.h - Simple request/response system for libcr
*
- * Copyright (C) 2024 Luke T. Shumaker <lukeshu@lukeshu.com>
+ * Copyright (C) 2024-2025 Luke T. Shumaker <lukeshu@lukeshu.com>
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
@@ -120,8 +120,10 @@
.cid = cr_getcid(), \
}; \
_cr_ipc_sll_push_to_rear(&ch->waiting_reqs, &self); \
- if (ch->waiting_resps.front) \
+ if (ch->waiting_resps.front) { \
cr_unpause(_cr_ipc_sll_node_cast(struct _##NAME##_waiting_resp, ch->waiting_resps.front)->cid); \
+ _cr_ipc_sll_pop_from_front(&ch->waiting_resps); \
+ } \
cr_pause_and_yield(); \
return resp; \
} \