Skip to content
Permalink
Browse files
fix auto https check
  • Loading branch information
devin.zhang committed May 1, 2022
1 parent be4d588 commit 2517b09cecec6f31a45f6f054584d0be64b33385
Showing 1 changed file with 2 additions and 2 deletions.
@@ -295,7 +295,7 @@ int Channel::InitSingle(const butil::EndPoint& server_addr_and_port,
if (raw_port != -1) {
_service_name.append(":").append(std::to_string(raw_port));
}
if (_options.protocol == brpc::PROTOCOL_HTTP && scheme == "https://") {
if (_options.protocol == brpc::PROTOCOL_HTTP && scheme == "https") {
if (_options.mutable_ssl_options()->sni_name.empty()) {
_options.mutable_ssl_options()->sni_name = _service_name;
}
@@ -336,7 +336,7 @@ int Channel::Init(const char* ns_url,
if (raw_port != -1) {
_service_name.append(":").append(std::to_string(raw_port));
}
if (_options.protocol == brpc::PROTOCOL_HTTP && scheme == "https://") {
if (_options.protocol == brpc::PROTOCOL_HTTP && scheme == "https") {
if (_options.mutable_ssl_options()->sni_name.empty()) {
_options.mutable_ssl_options()->sni_name = _service_name;
}

0 comments on commit 2517b09

Please sign in to comment.