雾聪 %!s(int64=2) %!d(string=hai) anos
pai
achega
29ce4c1526

+ 1 - 1
runtime/websocket/bin/funasr-wss-server-2pass.cpp

@@ -439,7 +439,7 @@ int main(int argc, char* argv[]) {
     funasr::ExtractHws(hotword_path, hws_map_);
     funasr::ExtractHws(hotword_path, hws_map_);
 
 
     bool is_ssl = false;
     bool is_ssl = false;
-    if (!s_certfile.empty()) {
+    if (!s_certfile.empty() && access(s_certfile.c_str(), F_OK) == 0) {
       is_ssl = true;
       is_ssl = true;
     }
     }
 
 

+ 1 - 1
runtime/websocket/bin/funasr-wss-server.cpp

@@ -419,7 +419,7 @@ int main(int argc, char* argv[]) {
     funasr::ExtractHws(hotword_path, hws_map_);
     funasr::ExtractHws(hotword_path, hws_map_);
 
 
     bool is_ssl = false;
     bool is_ssl = false;
-    if (!s_certfile.empty()) {
+    if (!s_certfile.empty() && access(s_certfile.c_str(), F_OK) == 0) {
       is_ssl = true;
       is_ssl = true;
     }
     }