Fixes #38 - fix response input stream handling