Fully unpipe the stream on error

fixes #23
closes #24
1.3.0