diff --git a/modules/core/src/persistence.cpp b/modules/core/src/persistence.cpp index f6544e918..04528c006 100644 --- a/modules/core/src/persistence.cpp +++ b/modules/core/src/persistence.cpp @@ -1319,6 +1319,8 @@ icvYMLParse( CvFileStorage* fs ) CV_PARSE_ERROR( "The YAML streams must start with '---', except the first one" ); break; } + else if( fs->dummy_eof ) + break; else CV_PARSE_ERROR( "Invalid or unsupported syntax" ); }