Fixed
Status Update
Comments
ad...@google.com <ad...@google.com>
ad...@google.com <ad...@google.com> #2
It seems like it's also not restarted when being killed due to a low memory condition. This is a serious issue!
cb...@google.com <cb...@google.com> #3
Same as 63618 issue reported before.
mm...@commonsware.com <mm...@commonsware.com> #4
Ruins battery notifications
Description
* What device are you using? (for example, Pixel XL)
PPP1.180208.014 (Pixel)
* What are the steps to reproduce the problem? (Please provide the minimal reproducible test case.)
Step #1: Read
Step #2: Download
Step #3: Install and run that project, which uses HttpURLConnection to download the content located at a plain HTTP URL
* Issue Category e.g. Framework (platform), NDK (platform), Hardware (CPU, GPU, Sensor, Camera), ART (platform), Runtime Permissions etc
Framework?
* What was the expected result?
A crash, with LogCat showing a stack trace indicating that I cannot download this, because it is in cleartext, as this project has targetSdkVersion 'P', and cleartext traffic is not supposed to be allowed by default
* What was the actual result?
The content is downloaded just fine.
If you modify the project to include a network security configuration with cleartextTrafficPermitted="false", then you get the expected crash:
Exception trying to download content
java.io.IOException: Cleartext HTTP traffic to
at com.android.okhttp.HttpHandler$CleartextURLFilter.checkURLPermitted(HttpHandler.java:115)
at com.android.okhttp.internal.huc.HttpURLConnectionImpl.execute(HttpURLConnectionImpl.java:458)
at com.android.okhttp.internal.huc.HttpURLConnectionImpl.getResponse(HttpURLConnectionImpl.java:407)
at com.android.okhttp.internal.huc.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:244)
at com.commonsware.android.hurl.secure.DownloadThread.run(DownloadThread.java:31)
However, according to the documentation, this crash is supposed to be happening by default.