Skip to content

Commit

Permalink
Fix compiler warning C4244 on MSVC.
Browse files Browse the repository at this point in the history
  • Loading branch information
ssexa authored and KingKili committed Dec 11, 2023
1 parent 67e2a4d commit 2f8cd6b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cpr/util.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ void secureStringClear(std::string& s) {

bool isTrue(const std::string& s) {
std::string temp_string{s};
std::transform(temp_string.begin(), temp_string.end(), temp_string.begin(), [](unsigned char c) { return std::tolower(c); });
std::transform(temp_string.begin(), temp_string.end(), temp_string.begin(), [](unsigned char c) { return static_cast<unsigned char>(std::tolower(c)); });
return temp_string == "true";
}

Expand Down

0 comments on commit 2f8cd6b

Please sign in to comment.