From 5d118b2b7446f14cc5aef83e41761c7439c9c50f Mon Sep 17 00:00:00 2001 From: Fangjun Kuang Date: Tue, 19 Sep 2023 12:48:30 +0800 Subject: [PATCH] Fix MFC examples --- CMakeLists.txt | 2 +- .../RealtimeSpeechRecognition/RealtimeSpeechRecognitionDlg.cpp | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 60b130f2..68d53c6d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.13 FATAL_ERROR) project(sherpa-ncnn) -set(SHERPA_NCNN_VERSION "2.1.2") +set(SHERPA_NCNN_VERSION "2.1.3") # Disable warning about # diff --git a/mfc-examples/RealtimeSpeechRecognition/RealtimeSpeechRecognitionDlg.cpp b/mfc-examples/RealtimeSpeechRecognition/RealtimeSpeechRecognitionDlg.cpp index 89d92b1a..c3f28ec3 100644 --- a/mfc-examples/RealtimeSpeechRecognition/RealtimeSpeechRecognitionDlg.cpp +++ b/mfc-examples/RealtimeSpeechRecognition/RealtimeSpeechRecognitionDlg.cpp @@ -413,6 +413,7 @@ void CRealtimeSpeechRecognitionDlg::InitRecognizer() { } SherpaNcnnRecognizerConfig config; + memset(&config, 0, sizeof(config)); config.model_config.num_threads = 1; config.decoder_config.decoding_method = "greedy_search";