I can't see a reason for this to depend on available(). The dispatch should only happen if there is data to read.
I can see good reasons for this not to depend on available(). The AsyncStateMachine has different behaviour on some state changes if it thinks async I/O is being used. With this test in place it was possible for some of those actions to be skipped.
|