whisper : fix bug in prompt processing (close #705)

Was dereferencing a dangling pointer
This commit is contained in:
Georgi Gerganov
2023-04-14 19:16:34 +03:00
parent 6704a81255
commit 514cd04452
2 changed files with 25 additions and 23 deletions

View File

@ -208,8 +208,8 @@ void whisper_print_segment_callback(struct whisper_context * ctx, struct whisper
std::string speaker = "";
int64_t t0;
int64_t t1;
int64_t t0 = 0;
int64_t t1 = 0;
// print the last n_new segments
const int s0 = n_segments - n_new;