DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6301>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=6301 Streams returned by getResourceAsStream don't close properly Summary: Streams returned by getResourceAsStream don't close properly Product: Tomcat 4 Version: 4.0.1 Final Platform: PC OS/Version: Windows NT/2K Status: NEW Severity: Major Priority: Other Component: Unknown AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] In our servlet we tried to get a resource as a stream so that we can read it using a java Properties object, this works successfully and we close the stream returned to us. If we then use getRealPath to get to the resource we have opened using getResourceAsStream, create a file output stream to it, write a new property to the properties file then close we can get a corrupt properties file with the old contents. It's as if the underlying inputstream has not been closed when we originally accessed the resource. We have tested this in Resin and our test behaved as we expected. -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>