Fix a compile error when SSL is disabled.
This commit is contained in:
+1
-1
@@ -78,7 +78,7 @@ void Client::Connect(RequestPtr request) {
|
||||
DoConnect(request, "443");
|
||||
#else
|
||||
LOG_ERRO("SSL/HTTPS support is not enabled.");
|
||||
return kSyntaxError;
|
||||
error_.Set(Error::kSyntaxError, "SSL/HTTPS is not supported");
|
||||
#endif // WEBCC_ENABLE_SSL
|
||||
} else {
|
||||
socket_.reset(new Socket{ io_context_ });
|
||||
|
||||
+2
-1
@@ -47,8 +47,9 @@ std::string FromExtension(const std::string& extension,
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
std::ostream& operator<<(std::ostream& os, const Error& error) {
|
||||
os << "ERROR(";
|
||||
os << std::to_string(static_cast<int>(error.code()));
|
||||
os << ": " << error.message();
|
||||
os << "): " << error.message();
|
||||
if (error.timeout()) {
|
||||
os << " (timeout)";
|
||||
}
|
||||
|
||||
@@ -97,6 +97,7 @@ static const bool g_terminal_has_color = []() {
|
||||
return strcmp(term, "cygwin") == 0 || strcmp(term, "linux") == 0 ||
|
||||
strcmp(term, "rxvt-unicode-256color") == 0 ||
|
||||
strcmp(term, "screen") == 0 || strcmp(term, "screen-256color") == 0 ||
|
||||
strcmp(term, "screen.xterm-256color") == 0 ||
|
||||
strcmp(term, "tmux-256color") == 0 || strcmp(term, "xterm") == 0 ||
|
||||
strcmp(term, "xterm-256color") == 0 ||
|
||||
strcmp(term, "xterm-termite") == 0 || strcmp(term, "xterm-color") == 0;
|
||||
|
||||
Reference in New Issue
Block a user