New issue
Advanced search Search tips

Issue 657995 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Feb 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 2
Type: Feature

Blocking:
issue 632867
issue 657994



Sign in to add a comment

When loading image placeholders, detect if the received subrange is the entire resource, and if so then show the full image instead of a placeholder.

Project Member Reported by sclit...@chromium.org, Oct 20 2016

Issue description

Project Member

Comment 2 by bugdroid1@chromium.org, Feb 15 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a2ef21fb88052a7c445d8646430170eb8e4447fd

commit a2ef21fb88052a7c445d8646430170eb8e4447fd
Author: sclittle <sclittle@chromium.org>
Date: Wed Feb 15 23:09:33 2017

Don't show a placeholder if the response contains the full image.

When attempting to load a placeholder image, it's possible that the
response contains the full image, e.g. if the image is smaller than the
requested range (e.g. requested the first 2KB of a 1KB image), if the
server ignored the range request header and returned a full 200
response, etc.

In these cases, this CL causes the full image to be shown and not get
treated as a placeholder image, instead of just showing a nondescript
placeholder image.

In order to detect when range responses contain the full image, this CL
refactors Content-Range response header parsing into http_util and
exposes it to Blink.

BUG= 657995 

Review-Url: https://codereview.chromium.org/2543073002
Cr-Commit-Position: refs/heads/master@{#450830}

[modify] https://crrev.com/a2ef21fb88052a7c445d8646430170eb8e4447fd/third_party/WebKit/Source/core/loader/resource/ImageResourceContent.cpp
[modify] https://crrev.com/a2ef21fb88052a7c445d8646430170eb8e4447fd/third_party/WebKit/Source/core/loader/resource/ImageResourceTest.cpp
[modify] https://crrev.com/a2ef21fb88052a7c445d8646430170eb8e4447fd/third_party/WebKit/Source/platform/network/HTTPParsers.cpp
[modify] https://crrev.com/a2ef21fb88052a7c445d8646430170eb8e4447fd/third_party/WebKit/Source/platform/network/HTTPParsers.h

Labels: -M-56 M-58
Status: Fixed (was: Assigned)

Sign in to add a comment