Prepare release 2.4.0
Fix InputStream leak (never close) and shadowing