mirror of
https://github.com/BeamMP/BeamMP-Launcher.git
synced 2026-10-28 07:00:16 +00:00
add ssl verify debug logging in a few places
This commit is contained in:
1 file changed
+7
-5
@@ -31,13 +31,15 @@ std::string HTTP::Get(const std::string &IP) {
|
||||
if(res){
|
||||
if (res->status == 200) {
|
||||
Ret = res->body;
|
||||
}else error(res->reason);
|
||||
|
||||
}
|
||||
else {
|
||||
error("Failed to GET '" + IP + "': " + res->reason + ", ssl verify = " + std::to_string(cli.get_openssl_verify_result()));
|
||||
}
|
||||
}else{
|
||||
if(isDownload) {
|
||||
std::cout << "\n";
|
||||
}
|
||||
error("HTTP Get failed on " + to_string(res.error()));
|
||||
error("HTTP Get failed on " + to_string(res.error()) + ", ssl verify = " + std::to_string(cli.get_openssl_verify_result()));
|
||||
}
|
||||
|
||||
return Ret;
|
||||
@@ -62,7 +64,7 @@ std::string HTTP::Post(const std::string& IP, const std::string& Fields) {
|
||||
}
|
||||
Ret = res->body;
|
||||
}else{
|
||||
error("HTTP Post failed on " + to_string(res.error()));
|
||||
error("HTTP Post failed on " + to_string(res.error()) + ", ssl verify = " + std::to_string(cli.get_openssl_verify_result()));
|
||||
}
|
||||
}else{
|
||||
httplib::Result res = cli.Post(IP.substr(pos).c_str());
|
||||
@@ -72,7 +74,7 @@ std::string HTTP::Post(const std::string& IP, const std::string& Fields) {
|
||||
}
|
||||
Ret = res->body;
|
||||
}else{
|
||||
error("HTTP Post failed on " + to_string(res.error()));
|
||||
error("HTTP Post failed on " + to_string(res.error()) + ", ssl verify = " + std::to_string(cli.get_openssl_verify_result()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user