Skip to content

Commit bb6cfc1

Browse files
committed
lstm: Initialize member variable beam_size_
Coverity report: CID 1366450 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR) 4. uninit_member: Non-static class member beam_size_ is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Stefan Weil <[email protected]>
1 parent 06b28a1 commit bb6cfc1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lstm/recodebeam.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ const int RecodeBeamSearch::kBeamWidths[RecodedCharID::kMaxCodeLen + 1] = {
4040
RecodeBeamSearch::RecodeBeamSearch(const UnicharCompress& recoder,
4141
int null_char, bool simple_text, Dict* dict)
4242
: recoder_(recoder),
43+
beam_size_(0),
4344
dict_(dict),
4445
space_delimited_(true),
4546
is_simple_text_(simple_text),

0 commit comments

Comments
 (0)