| Index: url/url_canon_relative.cc
|
| diff --git a/url/url_canon_relative.cc b/url/url_canon_relative.cc
|
| index 851368d8d4847a10ccdd12fa6b807e70822326cb..2ee61db24b7dfd642b66eb5e230b264d0a138b82 100644
|
| --- a/url/url_canon_relative.cc
|
| +++ b/url/url_canon_relative.cc
|
| @@ -441,8 +441,13 @@ bool DoResolveRelativeURL(const char* base_url,
|
| CharsetConverter* query_converter,
|
| CanonOutput* output,
|
| Parsed* out_parsed) {
|
| - // Starting point for our output parsed. We'll fix what we change.
|
| + // |base_parsed| is the starting point for our output. Since we may have
|
| + // removed whitespace from |relative_url| before entering this method, we'll
|
| + // carry over the |whitespace_removed| flag.
|
| + bool whitespace_removed = out_parsed->whitespace_removed;
|
| *out_parsed = base_parsed;
|
| + if (whitespace_removed)
|
| + out_parsed->whitespace_removed = true;
|
|
|
| // Sanity check: the input should have a host or we'll break badly below.
|
| // We can only resolve relative URLs with base URLs that have hosts and
|
|
|