FidReader left open in ShapefileRenderer ----------------------------------------
Key: GEOT-1742 URL: http://jira.codehaus.org/browse/GEOT-1742 Project: GeoTools Issue Type: Bug Components: ext shapefilerender Affects Versions: 2.4.1, 2.4.0 Environment: Sun OS Reporter: Enamul Haque ShapefileRenderer leaves fid reader open after rendering is complete. Here is the snippet from processShapefile() - Line 651-666: {noformat} private void processShapefile( Graphics2D graphics, ShapefileDataStore datastore, Envelope bbox, Rectangle screenSize, MathTransform mt, IndexInfo info, FeatureType type, Query query, List ruleList, List elseRuleList, Set modifiedFIDs, NumberRange scaleRange, String layerId ) throws IOException { ... finally { try { if (dbfreader != null) { dbfreader.close(); } } finally { try { if (shpreader != null) { shpreader.close(); } } finally { if (fidReader == null) // This is where the error is fidReader.close(); } } } } {noformat} The fix would be: {noformat} if (fidReader != null) fidReader.close(); {noformat} -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Geotools-devel mailing list Geotools-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geotools-devel