Don't hang if streaming response is cancelled before completion

Because threads writing to the streaming response buffer aren't able to check if the buffer has been closed, server instances can stop responding if a user cancels a streaming request before it completes, leaving threads writing to the response buffer blocked in ```@buf.push```.