mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-04 09:56:30 +00:00
DIRECTOR: Fix unchecked return value
getChildren returns false when not succesful, i.e. meaning we can bail out of the loop iteration. Fixes COVERITY: 1462418
This commit is contained in:
parent
891fa08f15
commit
9aafdcf976
@ -421,7 +421,9 @@ bool testPath(Common::String &path, bool directory) {
|
||||
if (directory_list.empty() && !directory) {
|
||||
mode = Common::FSNode::kListAll;
|
||||
}
|
||||
d.getChildren(fslist, mode);
|
||||
bool hasChildren = d.getChildren(fslist, mode);
|
||||
if (!hasChildren)
|
||||
continue;
|
||||
|
||||
bool exists = false;
|
||||
for (Common::FSList::iterator i = fslist.begin(); i != fslist.end(); ++i) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user