1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 23:33:05 +04:00

operator<< handles keys starting with underscore

This commit is contained in:
Philipp Hasper
2016-04-11 09:55:33 +02:00
parent 06ea0aa02b
commit 47c4ee974a
2 changed files with 12 additions and 1 deletions
+1 -1
View File
@@ -5217,7 +5217,7 @@ FileStorage& operator << (FileStorage& fs, const String& str)
}
else if( fs.state == NAME_EXPECTED + INSIDE_MAP )
{
if( !cv_isalpha(*_str) )
if (!cv_isalpha(*_str) && *_str != '_')
CV_Error_( CV_StsError, ("Incorrect element name %s", _str) );
fs.elname = str;
fs.state = VALUE_EXPECTED + INSIDE_MAP;