diff --git a/src/extra/nnue_data_binpack_format.h b/src/extra/nnue_data_binpack_format.h index 826b2959..b9e45c3e 100644 --- a/src/extra/nnue_data_binpack_format.h +++ b/src/extra/nnue_data_binpack_format.h @@ -6141,6 +6141,11 @@ namespace binpack [[nodiscard]] bool hasNextChunk() { + if (!m_file) + { + return false; + } + m_file.peek(); return !m_file.eof(); }