mirror of
https://github.com/oxen-io/session-android.git
synced 2024-12-22 07:57:30 +00:00
When retrieving MMS, continue on with best-effort in absence of APNs.
This commit is contained in:
parent
5050b43234
commit
47c83d2747
@ -50,14 +50,16 @@ public class MmsDownloadHelper extends MmsCommunication {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static byte[] retrieveMms(Context context, String url, String apn) throws IOException {
|
public static byte[] retrieveMms(Context context, String url, String apn) throws IOException {
|
||||||
try {
|
MmsConnectionParameters connectionParameters;
|
||||||
MmsConnectionParameters connectionParameters = getMmsConnectionParameters(context, apn);
|
|
||||||
|
|
||||||
checkRouteToHost(context, connectionParameters, url);
|
try {
|
||||||
return makeRequest(connectionParameters, url);
|
connectionParameters = getMmsConnectionParameters(context, apn);
|
||||||
} catch (MmsException me) {
|
} catch (MmsException me) {
|
||||||
Log.w("MmsDownloader", me);
|
Log.w("MmsDownloadHelper", me);
|
||||||
throw new IOException("Problem configuring MmsConnectionParameters.");
|
connectionParameters = new MmsConnectionParameters(null, null, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
checkRouteToHost(context, connectionParameters, url);
|
||||||
|
return makeRequest(connectionParameters, url);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user