HTTPCLIENT-1135: RandomAccessFile mode w is not valid

git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1180373 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Oleg Kalnichevski 2011-10-08 13:12:12 +00:00
parent 28de736437
commit 61ab54d99d
1 changed files with 1 additions and 1 deletions

View File

@ -69,7 +69,7 @@ class IOUtils {
static void copyFile(final File in, final File out) throws IOException { static void copyFile(final File in, final File out) throws IOException {
RandomAccessFile f1 = new RandomAccessFile(in, "r"); RandomAccessFile f1 = new RandomAccessFile(in, "r");
RandomAccessFile f2 = new RandomAccessFile(out, "w"); RandomAccessFile f2 = new RandomAccessFile(out, "rw");
try { try {
FileChannel c1 = f1.getChannel(); FileChannel c1 = f1.getChannel();
FileChannel c2 = f2.getChannel(); FileChannel c2 = f2.getChannel();