diff --git a/system/jlib/jptree.cpp b/system/jlib/jptree.cpp index e9f19075d0a..c15302f35ea 100644 --- a/system/jlib/jptree.cpp +++ b/system/jlib/jptree.cpp @@ -1368,9 +1368,8 @@ bool PTree::hasProp(const char * xpath) const } else { - IPropertyTreeIterator *iter = getElements(xpath); + Owned iter = getElements(xpath); bool res = iter->first(); - iter->Release(); return res; } }