Harden several SocketsHttpHandler streams against unexpected Dispose (dotnet/corefx#37299)
A few tweaks:
- We hand out the ChunkedEncodingWriteStream and ContentLengthWriteStream to an HttpContent.SerializeToStreamAsync. If that user code disposes of the Stream, then we end up null ref'ing when we try to finish the processing. We should instead throw a more descriptive error about the misuse.
- Make the non-pooled response streams slightly more robust against concurrent disposal (which is not a supported use, but it happens).
Commit migrated from https://github.com/dotnet/corefx/commit/
422565673deb849b42f656f4a68bec791ee4bed9