Fixed another bug in Data Downloader
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
// This string is autogenerated by ChangeAppSettings.sh, do not change spaces amount
|
||||
package com.sourceforge.sc2;
|
||||
package de.schwardtnet.alienblaster;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.Context;
|
||||
@@ -243,6 +243,8 @@ class DataDownloader extends Thread
|
||||
System.out.println("Failed to connect to " + url);
|
||||
downloadUrlIndex++;
|
||||
}
|
||||
else
|
||||
break;
|
||||
}
|
||||
}
|
||||
if( response == null )
|
||||
@@ -267,6 +269,10 @@ class DataDownloader extends Thread
|
||||
downloadUrls[downloadUrlIndex].indexOf(":", 1) ));
|
||||
OutputStream out = null;
|
||||
try {
|
||||
try {
|
||||
(new File( path.substring(0, path.lastIndexOf("/") ))).mkdirs();
|
||||
} catch( SecurityException e ) { };
|
||||
|
||||
out = new FileOutputStream( path );
|
||||
} catch( FileNotFoundException e ) {
|
||||
} catch( SecurityException e ) { };
|
||||
|
||||
Reference in New Issue
Block a user