Skip to content

Commit 054cf81

Browse files
authored
remove redundant File.length() check to fix race condition
See codehaus-plexus#47
1 parent 2b10af4 commit 054cf81

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

src/main/java/org/codehaus/plexus/util/FileUtils.java

-6
Original file line numberDiff line numberDiff line change
@@ -1080,12 +1080,6 @@ public static void copyFile( final File source, final File destination )
10801080
mkdirsFor( destination );
10811081

10821082
doCopyFile( source, destination );
1083-
1084-
if ( source.length() != destination.length() )
1085-
{
1086-
String message = "Failed to copy full contents from " + source + " to " + destination;
1087-
throw new IOException( message );
1088-
}
10891083
}
10901084

10911085
private static void doCopyFile( File source, File destination )

0 commit comments

Comments
 (0)