maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vsive...@apache.org
Subject svn commit: r749004 - /maven/plugins/branches/maven-site-plugin-doxia-beta-1/src/main/java/org/apache/maven/plugins/site/ReportDocumentRenderer.java
Date Sun, 01 Mar 2009 11:55:55 GMT
Author: vsiveton
Date: Sun Mar  1 11:55:55 2009
New Revision: 749004

URL: http://svn.apache.org/viewvc?rev=749004&view=rev
Log:
o be sure to close sink

Modified:
    maven/plugins/branches/maven-site-plugin-doxia-beta-1/src/main/java/org/apache/maven/plugins/site/ReportDocumentRenderer.java

Modified: maven/plugins/branches/maven-site-plugin-doxia-beta-1/src/main/java/org/apache/maven/plugins/site/ReportDocumentRenderer.java
URL: http://svn.apache.org/viewvc/maven/plugins/branches/maven-site-plugin-doxia-beta-1/src/main/java/org/apache/maven/plugins/site/ReportDocumentRenderer.java?rev=749004&r1=749003&r2=749004&view=diff
==============================================================================
--- maven/plugins/branches/maven-site-plugin-doxia-beta-1/src/main/java/org/apache/maven/plugins/site/ReportDocumentRenderer.java
(original)
+++ maven/plugins/branches/maven-site-plugin-doxia-beta-1/src/main/java/org/apache/maven/plugins/site/ReportDocumentRenderer.java
Sun Mar  1 11:55:55 2009
@@ -171,6 +171,10 @@
         {
             throw new RendererException( "Error rendering Maven report: " + e.getMessage(),
e );
         }
+        finally
+        {
+            sink.close();
+        }
 
         if ( !report.isExternalReport() )
         {
@@ -188,7 +192,14 @@
 
                     Writer out = new FileWriter( new File( mySink.getOutputDir(), mySink.getOutputName()
) );
 
-                    renderer.generateDocument( out, mySink, siteRenderingContext );
+                    try
+                    {
+                        renderer.generateDocument( out, mySink, siteRenderingContext );
+                    }
+                    finally
+                    {
+                        mySink.close();
+                    }
                 }
             }
             catch ( IOException e )



Mime
View raw message