Explorar el Código

add buffer for nullptr res

雾聪 hace 2 años
padre
commit
37f078ef5f
Se han modificado 1 ficheros con 1 adiciones y 0 borrados
  1. 1 0
      runtime/websocket/bin/websocket-server.cpp

+ 1 - 0
runtime/websocket/bin/websocket-server.cpp

@@ -85,6 +85,7 @@ void WebSocketServer::do_decoder(const std::vector<char>& buffer,
           stamp_sents = FunASRGetStampSents(Result);
           FunASRFreeResult(Result);
         } else{
+          std::this_thread::sleep_for(std::chrono::milliseconds(20));
           LOG(ERROR) << "FUNASR_RESULT is nullptr.";
         }
       }catch (std::exception const& e) {