aboutsummaryrefslogtreecommitdiff
path: root/src/httprpc.cpp
diff options
context:
space:
mode:
authorPieter Wuille <pieter@wuille.net>2022-04-04 15:05:47 -0400
committerMacroFake <falke.marco@gmail.com>2022-04-27 14:13:39 +0200
commite7d2fbda63c346ae88767c3f8d4db3edeae2dc0b (patch)
tree4dd8119287a61d27f9b95b2a33a946ac8120d7e9 /src/httprpc.cpp
parent8ffbd1412d887535ce5eb613884858c319bd12be (diff)
Use std::string_view throughout util strencodings/string
Diffstat (limited to 'src/httprpc.cpp')
-rw-r--r--src/httprpc.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/httprpc.cpp b/src/httprpc.cpp
index b9041227be..93d9acf5da 100644
--- a/src/httprpc.cpp
+++ b/src/httprpc.cpp
@@ -131,7 +131,7 @@ static bool RPCAuthorized(const std::string& strAuth, std::string& strAuthUserna
return false;
if (strAuth.substr(0, 6) != "Basic ")
return false;
- std::string strUserPass64 = TrimString(strAuth.substr(6));
+ std::string_view strUserPass64 = TrimStringView(std::string_view{strAuth}.substr(6));
auto userpass_data = DecodeBase64(strUserPass64);
std::string strUserPass;
if (!userpass_data) return false;