Commit ae63fcb7 authored by toaster's avatar toaster
Browse files

patch to SWAP driver to prevent early exiting

git-svn-id: https://subversion.umiacs.umd.edu/ace/trunk@111 f1b3a171-7291-4a19-a512-95ad0ad9394a
parent c0a8be80
......@@ -92,7 +92,11 @@ public final class SwapIterator implements Iterator<FileBean> {
if ( basePath != null ) {
for ( MonitoredItem mi : basePath ) {
String startFile;
if (rootFile.getFullPath().equals("/"))
startFile = mi.getPath();
else
startFile = rootFile.getFullPath() + mi.getPath();
LOG.trace("Supplied file for processing: " + startFile);
SwapFile sf = rootFile.getFileGroup().getFileDetails(startFile);
if ( mi.isDirectory() ) {
......@@ -290,7 +294,7 @@ if (rootFile.getFullPath().equals("/"))
new ThrottledInputStream(connection.getInputStream(), QueryThrottle.getMaxBps(), lastDelay);
dis = new DigestInputStream(tis, digest);
int read = 0;
while ( (read = dis.read(buffer)) >= 0 && !finished ) {
while ( (read = dis.read(buffer)) >= 0) {
fileSize += read;
statebean.updateLastChange();
statebean.setRead(fileSize);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment