summaryrefslogtreecommitdiff
path: root/rs/java/android/renderscript/ProgramFragmentFixedFunction.java
diff options
context:
space:
mode:
authorHugo Benichi <hugobenichi@google.com>2017-01-11 16:23:26 +0900
committerHugo Benichi <hugobenichi@google.com>2017-02-16 12:31:30 +0900
commite3aae40d07bae209c7b7dd608175563857f67ba6 (patch)
treee8c231385867d6304f6d7eedd15ec7e828f2f276 /rs/java/android/renderscript/ProgramFragmentFixedFunction.java
parented6d75d5f31dd69d2c91cd82cddd5ee1db49b2c7 (diff)
Captive portal: better detect empty responses
The captive portal detection logic treats empty http responses with a Content-Length of 0 as not coming from a portal. However when the Content-Length is missing from the response header, the empty response is not detected as such and is classified as a captive portal answer. When this happens for the http probe, the portal detection logic will short circuit the detection and wrongly report a portal. The system validates the network in such conditions only if the https probe returns a successful connection faster than the http probe. This patch attempts to better detect empty responses by trying to read the first byte from the response body when the Content-Length is missing for 200 responses. Test: build, flashed + manual tests. Bug: 33498325 (cherry picked from commit cb4aa4d412c7940386df9b8dd681e0d2efebfd1d) Change-Id: Ibb9914cba72a4dab3ae76746d8889bbf083be812
Diffstat (limited to 'rs/java/android/renderscript/ProgramFragmentFixedFunction.java')
0 files changed, 0 insertions, 0 deletions