libcamera: yaml_parser: Extend YamlObject::size() to dictionaries
Dictionaries have a size too, extend the size() function to support them. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
This commit is contained in:
parent
27483e971f
commit
27fb47f70b
3 changed files with 30 additions and 20 deletions
|
@ -421,6 +421,11 @@ protected:
|
|||
return TestFail;
|
||||
}
|
||||
|
||||
if (dictObj.size() != 3) {
|
||||
cerr << "Dictionary object parse with wrong size" << std::endl;
|
||||
return TestFail;
|
||||
}
|
||||
|
||||
auto memeberNames = dictObj.memberNames();
|
||||
sort(memeberNames.begin(), memeberNames.end());
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue