Fix up state detection for closing stream Also add cancellation token support for waiting
Fix up state detection for closing stream
Also add cancellation token support for waiting

Redth/HttpTwo,Redth/HttpTwo,Redth/HttpTwo