diff --git a/src/URI.cc b/src/URI.cc index ff46ea82e..81ab22c2c 100644 --- a/src/URI.cc +++ b/src/URI.cc @@ -587,6 +587,7 @@ URIPath &URIPath::operator=(const URIPath &_path) { this->dataPtr->path = _path.dataPtr->path; this->dataPtr->isAbsolute = _path.dataPtr->isAbsolute; + this->dataPtr->trailingSlash = _path.dataPtr->trailingSlash; return *this; } diff --git a/src/URI_TEST.cc b/src/URI_TEST.cc index b4c76ff1d..4b2301bc3 100644 --- a/src/URI_TEST.cc +++ b/src/URI_TEST.cc @@ -890,8 +890,8 @@ TEST(URITEST, HasAuthority) // Modifyng path updates string uri.Path() = URIPath("new_authority.com/another/path"); - EXPECT_EQ("new_authority.com/another/path/", uri.Path().Str()); - EXPECT_EQ("https://new_authority.com/another/path/", uri.Str()); + EXPECT_EQ("new_authority.com/another/path", uri.Path().Str()); + EXPECT_EQ("https://new_authority.com/another/path", uri.Str()); // Clearing keeps false authority uri.Clear();