diff options
author | jww <jww@chromium.org> | 2015-06-30 16:18:35 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-06-30 23:19:07 +0000 |
commit | f6a77e6f05c7dfe02238873de39d995d3fcab79e (patch) | |
tree | 7e967dca1deb2aaabf5963f6d4d02a7454b85359 /net/websockets/websocket_deflate_stream.h | |
parent | dffcf17c7f07259f672cbe831dc0039364bd8a14 (diff) | |
download | chromium_src-f6a77e6f05c7dfe02238873de39d995d3fcab79e.zip chromium_src-f6a77e6f05c7dfe02238873de39d995d3fcab79e.tar.gz chromium_src-f6a77e6f05c7dfe02238873de39d995d3fcab79e.tar.bz2 |
Fix incorrect tab title for file:// URLs with reference or query params
This addresses a bug where a tab with a file:// URL with a reference or
query parameter that contains a '/' character (and no explicit <title>
tag) displays an incorrect title. In particular, in displays all of the
URL after the last '/' in reference or query parameter. This is
particularly confusing if the reference or query parameter contains a
URL itself. For example, the URL file:///a/b/foo#http://baz.com displays
a tab title of 'baz.com'.
The problem is that, for file:// URLs, Chrome only wants to display the
filename in the tab title, rather than the entire origin as is done for
all other URLs. Unfortunately, the title parser simply searches for the
last '/' character, which in the cases described above does not define
the filename. This fix searches for the first '#' or '?' and then
searches for the first '/' character before that.
BUG=503003
Review URL: https://codereview.chromium.org/1206753002
Cr-Commit-Position: refs/heads/master@{#336909}
Diffstat (limited to 'net/websockets/websocket_deflate_stream.h')
0 files changed, 0 insertions, 0 deletions