From: Emin Date: Tue, 10 Jun 2025 09:03:21 +0000 (+0200) Subject: fix: Revert url_decode to old behaviour X-Git-Tag: v19.2.3~13^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=80b044e202a8b7ebd21b5c498946d9bd59b282bb;p=ceph-ci.git fix: Revert url_decode to old behaviour Signed-off-by: Emin (cherry picked from commit c603ce719aca906d75af60e7d31bf13db09d8ec6) --- diff --git a/src/rgw/rgw_common.cc b/src/rgw/rgw_common.cc index 3ba07361c19..f32e4b97c62 100644 --- a/src/rgw/rgw_common.cc +++ b/src/rgw/rgw_common.cc @@ -1723,14 +1723,13 @@ std::string url_decode(const std::string_view& src_str, bool in_query) const char c1 = hex_to_num(*src++); const char c2 = hex_to_num(*src); if (c1 < 0 || c2 < 0) { - src--; - src--; //going back to the % - dest_str.push_back(*src); //add % to the target destination string + return std::string(); } else { dest_str.push_back(c1 << 4 | c2); } } } + return dest_str; }