Wow I wasn't even close

This commit is contained in:
Adam
2015-10-16 19:26:43 -04:00
parent ad63c9d423
commit 302f0bcfe1
2 changed files with 23 additions and 19 deletions

View File

@@ -488,6 +488,12 @@ public class Index implements Closeable
} }
else else
{ {
for (int i = 0; i < filesCount; ++i)
{
File file = a.getFiles().get(i);
stream.writeBytes(file.getContents());
}
for (int count = 0; count < filesCount; ++count) for (int count = 0; count < filesCount; ++count)
{ {
File file = a.getFiles().get(count); File file = a.getFiles().get(count);
@@ -499,23 +505,21 @@ public class Index implements Closeable
int prevLen = 0; int prevLen = 0;
for (int i = 0; i < filesCount; ++i) // for (int i = 0; i < filesCount; ++i)
{ // {
File file = a.getFiles().get(i); // File file = a.getFiles().get(i);
//
int len = file.getSize() - prevLen; // int len = file.getSize() - prevLen;
//int fid = file.getFileId() - fileId; // //int fid = file.getFileId() - fileId;
//fileId = file.getFileId(); // //fileId = file.getFileId();
stream.writeInt(len); // stream.writeInt(len);
prevLen = file.getSize(); // prevLen = file.getSize();
//
stream.writeBytes(file.getContents()); // // fileId += stream.readInt();
// // System.arraycopy(data, sourceOffset, var18[i], filesSize[i], fileId);
// fileId += stream.readInt(); // // sourceOffset += fileId;
// System.arraycopy(data, sourceOffset, var18[i], filesSize[i], fileId); // // filesSize[i] += fileId;
// sourceOffset += fileId; // }
// filesSize[i] += fileId;
}
stream.writeByte(1); // number of loops stream.writeByte(1); // number of loops
} }

View File

@@ -16,7 +16,7 @@ public class StoreTest
@BeforeClass @BeforeClass
public static void before() public static void before()
{ {
System.setProperty("java.io.tmpdir", "c:/rs/temp"); System.setProperty("java.io.tmpdir", "d:/rs/07/temp/");
} }
@Test @Test