close stream
diff --git a/maven-scm-test/src/main/java/org/apache/maven/scm/tck/command/checkin/CheckInCommandTckTest.java b/maven-scm-test/src/main/java/org/apache/maven/scm/tck/command/checkin/CheckInCommandTckTest.java
index 55069ee..f120926 100644
--- a/maven-scm-test/src/main/java/org/apache/maven/scm/tck/command/checkin/CheckInCommandTckTest.java
+++ b/maven-scm-test/src/main/java/org/apache/maven/scm/tck/command/checkin/CheckInCommandTckTest.java
@@ -39,7 +39,6 @@
* This test tests the check out command.
*
* @author <a href="mailto:brett@apache.org">Brett Porter</a>
- *
*/
public abstract class CheckInCommandTckTest
extends ScmTckTestCase
@@ -231,10 +230,17 @@
private void changeReadmeTxt( File readmeTxt )
throws Exception
{
- FileWriter output = new FileWriter( readmeTxt );
+ FileWriter output = null;
- output.write( "changed file" );
+ try
+ {
+ output = new FileWriter( readmeTxt );
- output.close();
+ output.write( "changed file" );
+ }
+ finally
+ {
+ IOUtil.close( output );
+ }
}
}