Commit e5280c6
committed
Fix coroutine scope tracking race condition
Move scope reference assignment from async_new_coroutine() to scope_before_coroutine_enqueue()
to ensure coroutines are added to scope->coroutines array before scope is set. This prevents
crashes when coroutines finish between creation and enqueue.
Fixes assertion failures: "Scope should be empty before disposal"1 parent 29f050b commit e5280c6
2 files changed
+13
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
106 | 106 | | |
107 | 107 | | |
108 | 108 | | |
109 | | - | |
110 | | - | |
111 | | - | |
112 | | - | |
113 | | - | |
114 | | - | |
115 | | - | |
116 | | - | |
117 | | - | |
118 | 109 | | |
119 | 110 | | |
120 | 111 | | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
121 | 115 | | |
122 | 116 | | |
123 | 117 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
337 | 337 | | |
338 | 338 | | |
339 | 339 | | |
340 | | - | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
| 344 | + | |
| 345 | + | |
| 346 | + | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
341 | 350 | | |
342 | 351 | | |
343 | 352 | | |
| |||
0 commit comments