mirror of
https://github.com/boostorg/url.git
synced 2026-01-19 04:42:15 +00:00
@@ -1580,6 +1580,8 @@ resolve(
|
||||
if(ref.has_fragment())
|
||||
set_encoded_fragment(
|
||||
ref.encoded_fragment());
|
||||
else
|
||||
remove_fragment();
|
||||
return {};
|
||||
}
|
||||
if(ref.is_path_absolute())
|
||||
|
||||
@@ -1047,6 +1047,15 @@ struct url_test
|
||||
BOOST_TEST_CSTR_EQ(u, "https:path2");
|
||||
}
|
||||
}
|
||||
|
||||
// issue #920
|
||||
{
|
||||
url u("https://www.example.org/path/index.html?a%20b=5%206&x%20y=34#frag");
|
||||
url ref("?asdf%20qwer=1%202%20");
|
||||
BOOST_TEST(u.resolve(ref));
|
||||
BOOST_TEST_CSTR_EQ(u.buffer(), "https://www.example.org/path/index.html?asdf%20qwer=1%202%20");
|
||||
BOOST_TEST(!u.has_fragment());
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user