[ https://issues.apache.org/jira/browse/HADOOP-5476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Chris Douglas updated HADOOP-5476: ---------------------------------- Status: Open (was: Patch Available) Thanks for updating the patch; I meant the first try/finally, which is actually distinguishing the case where an IOException is thrown from the case where it is not. That is better expressed as: {code} this.conf = conf; try { seek(start); this.end = in.getPos() + length; init(tempReader); } catch (IOException e) { try { in.close(); } catch (IOException ce) { LOG.info("Exception from close in init: ", ce); } throw e; } {code} or even more succinctly: {code} try { seek(start); this.end = in.getPos() + length; init(tempReader); } catch (IOException e) { IOUtils.cleanup(LOG, in); throw e; } {code} > calling new SequenceFile.Reader(...) leaves an InputStream open, if the given > sequence file is broken > ----------------------------------------------------------------------------------------------------- > > Key: HADOOP-5476 > URL: https://issues.apache.org/jira/browse/HADOOP-5476 > Project: Hadoop Core > Issue Type: Bug > Components: io > Affects Versions: 0.20.0, 0.19.1 > Reporter: Michael Tamm > Assignee: Michael Tamm > Attachments: test_and_fix_for_HADOOP-5476.patch, > updated_test_and_fix_for_HADOOP-5476.patch > > -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.