Break the patching out into a separate phase, clean up the diff and old
jar files when we're done patching. git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2741 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: DownloadManager.java,v 1.8 2003/08/05 01:33:20 mdb Exp $
|
||||
// $Id: DownloadManager.java,v 1.9 2003/08/05 07:03:33 mdb Exp $
|
||||
|
||||
package com.threerings.resource;
|
||||
|
||||
@@ -257,6 +257,7 @@ public class DownloadManager
|
||||
}
|
||||
|
||||
Log.info("Initiating download of " + pinfo.totalSize + " bytes.");
|
||||
|
||||
// download all stale files
|
||||
size = fetch.size();
|
||||
pinfo.start = System.currentTimeMillis();
|
||||
@@ -272,6 +273,19 @@ public class DownloadManager
|
||||
}
|
||||
}
|
||||
|
||||
// now go through and do the post-download phase
|
||||
for (int ii = 0; ii < size; ii++) {
|
||||
Downloader loader = (Downloader)fetch.get(ii);
|
||||
try {
|
||||
loader.postDownload(this, obs, pinfo);
|
||||
} catch (IOException ioe) {
|
||||
notifyFailed(obs, loader.getDescriptor(), ioe);
|
||||
if (fragile) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// make sure to always let the observer know that we've wrapped up
|
||||
// by reporting 100% completion
|
||||
notifyProgress(obs, 100, 0L);
|
||||
|
||||
Reference in New Issue
Block a user