camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "edge wang (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CAMEL-4265) Fail to close stream in DefaultPropertiesResolver
Date Fri, 29 Jul 2011 14:30:11 GMT

    [ https://issues.apache.org/jira/browse/CAMEL-4265?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13072842#comment-13072842
] 

edge wang commented on CAMEL-4265:
----------------------------------

ok, thanks.

> Fail to close stream in DefaultPropertiesResolver
> -------------------------------------------------
>
>                 Key: CAMEL-4265
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4265
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-core
>    Affects Versions: 2.7.3, 2.8.0
>         Environment: Any
>            Reporter: edge wang
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.9.0
>
>         Attachments: close_inputstream.patch, close_inputstream.patch
>
>
>     protected Properties loadPropertiesFromFilePath(CamelContext context, String path)
throws IOException {
>         if (path.startsWith("file:")) {
>             path = ObjectHelper.after(path, "file:");
>         }
>         InputStream is = new FileInputStream(path);
>         Properties answer = new Properties();
>         answer.load(is);
>         return answer;
>     }
>     Stream not closed before return, as well as in another method: loadPropertiesFromClasspath.
   

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message