summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorTyge Løvset <[email protected]>2023-02-28 19:37:26 +0100
committerTyge Løvset <[email protected]>2023-02-28 19:37:26 +0100
commit8fdcfbf621b5e8c1298a89579594db0817adce26 (patch)
tree8515b7b39c3fc360cffbc5ee5f34a86ab55d4d75
parent27e419388b4cee6ea972344ff24cc7ad76d3e8b0 (diff)
downloadSTC-modified-8fdcfbf621b5e8c1298a89579594db0817adce26.tar.gz
STC-modified-8fdcfbf621b5e8c1298a89579594db0817adce26.zip
Fixed stopping of sub-coroutines.
-rw-r--r--include/stc/algo/coroutine.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/include/stc/algo/coroutine.h b/include/stc/algo/coroutine.h
index 40a98836..f3e42165 100644
--- a/include/stc/algo/coroutine.h
+++ b/include/stc/algo/coroutine.h
@@ -101,7 +101,6 @@ enum {
goto _cco_final_
#define cco_stop(ctx) \
- (((ctx)->cco_state = cco_alive(ctx) ? \
- cco_state_final : cco_state_expired), ctx)
+ (cco_alive(ctx) ? ((ctx)->cco_state = cco_state_final) : 0, ctx)
#endif