Issue Type: Bug Bug
Affects Versions: current
Assignee: Michal Turek
Components: sloccount
Created: 05/Jan/14 10:18 AM
Description:

If an exception occurs before the stream is closed there will be a resource leak since close() won't be called. Use try-finally pattern.

    private void parse(java.io.File file, SloccountReportInterface report) throws IOException {
        InputStreamReader in = new InputStreamReader(new FileInputStream(file), encoding);
        this.parse(in, report);
        in.close();
    }
Environment: Bug in code logic
Project: Jenkins
Priority: Major Major
Reporter: Michal Turek
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira

--
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to