http upload: do not crash on invalid slot responses
This commit is contained in:
parent
e2ac1db225
commit
64928d0ff1
|
@ -145,11 +145,11 @@ public class HttpUploadConnection implements Transferable {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (!canceled) {
|
if (!canceled) {
|
||||||
new Thread(this::upload).start();
|
new Thread(this::upload).start();
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
} catch (MalformedURLException e) {
|
} catch (MalformedURLException e) {
|
||||||
//fall through
|
//fall through
|
||||||
}
|
}
|
||||||
|
@ -229,7 +229,9 @@ public class HttpUploadConnection implements Transferable {
|
||||||
if (connection != null) {
|
if (connection != null) {
|
||||||
connection.disconnect();
|
connection.disconnect();
|
||||||
}
|
}
|
||||||
|
if (wakeLock.isHeld()) {
|
||||||
wakeLock.release();
|
wakeLock.release();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue