add context cancellation to disk windows#1943
Conversation
|
Sorry for late reponse. Great work on adding context cancellation! However, I noticed the context checking pattern is inconsistent across the loop implementations:
For consistency and following Go idioms, I'd recommend using |
done, now loops uses select with context |
shirou
left a comment
There was a problem hiding this comment.
Thank you for updating the PR. The context cancellation implementation looks good - it properly checks for cancellation at each loop iteration without leaking goroutines. LGTM!
I readded context cancellation. context is cancelled as soon as possible, but there are no leaking goroutines, if a system call blocks, code returns as soon as the system call returns.