am ed009be9: (-s ours) DO NOT MERGE. Merge commit \'4602bf9d\' into mergeit
Jeff Sharkey [Fri, 8 Mar 2013 19:04:20 +0000 (11:04 -0800)]
* commit 'ed009be9799ddfe554745c8aeb8f2ad47a10945b':
  Fix large file download failure issue

src/com/android/providers/downloads/DownloadThread.java

index d4f14f0..34bc8e3 100644 (file)
@@ -514,7 +514,7 @@ public class DownloadThread extends Thread {
         mContext.getContentResolver().update(mInfo.getAllDownloadsUri(), values, null, null);
 
         boolean lengthMismatched = (innerState.mHeaderContentLength != null)
-                && (state.mCurrentBytes != Long.parseLong(innerState.mHeaderContentLength));
+                && (state.mCurrentBytes != Integer.parseInt(innerState.mHeaderContentLength));
         if (lengthMismatched) {
             if (cannotResume(state)) {
                 throw new StopRequestException(Downloads.Impl.STATUS_CANNOT_RESUME,