Commit d62c39f
committed
core: fix pipelined set failures on pending reads
- IO objects are enqueued per-worker-thread since a refactor in ec1fb56
- If a set payload is being read off the network but the read gets
EAGAIN, _and_ there are already pending IO objects on the connection,
the worker thread will execute the pending IOs
- The worker resume code did not check for conn_nread state and would
resume the connection's state machine if those IO's completed before
the conn_nread state completes.
- The connection state is now corrupt and will both leak memory and
throw parsing errors.
This is a one-line fix to avoid resuming the state machine if we were in
conn_nread state, as well as avoiding finalizing a connection from the
conn_closing state if there are pending suspended responses.1 parent a5b3ce9 commit d62c39f
1 file changed
Lines changed: 8 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
551 | 551 | | |
552 | 552 | | |
553 | 553 | | |
| 554 | + | |
| 555 | + | |
554 | 556 | | |
555 | 557 | | |
556 | 558 | | |
| |||
3319 | 3321 | | |
3320 | 3322 | | |
3321 | 3323 | | |
3322 | | - | |
3323 | | - | |
3324 | | - | |
3325 | | - | |
| 3324 | + | |
| 3325 | + | |
| 3326 | + | |
| 3327 | + | |
| 3328 | + | |
| 3329 | + | |
3326 | 3330 | | |
3327 | 3331 | | |
3328 | 3332 | | |
| |||
0 commit comments