-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🐛 don't close source after processing partial request without cache #43
prevent invalid calling source.close() in different threads to avoid crashes on Lollipop (#37, #29, #63, #66)
- Loading branch information
Showing
5 changed files
with
121 additions
and
27 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -78,10 +78,11 @@ public void close() throws ProxyCacheException { | |
if (connection != null) { | ||
try { | ||
connection.disconnect(); | ||
} catch (NullPointerException e) { | ||
// https://github.com/danikula/AndroidVideoCache/issues/32 | ||
// https://github.com/danikula/AndroidVideoCache/issues/29 | ||
throw new ProxyCacheException("Error disconnecting HttpUrlConnection", e); | ||
} catch (NullPointerException | IllegalArgumentException e) { | ||
String message = "Wait... but why? WTF!? " + | ||
"Really shouldn't happen any more after fixing https://github.com/danikula/AndroidVideoCache/issues/43. " + | ||
"If you read it on your device log, please, notify me [email protected] or create issue here https://github.com/danikula/AndroidVideoCache/issues."; | ||
throw new RuntimeException(message, e); | ||
} | ||
} | ||
} | ||
|
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters