Pop only completed child elements.

git-svn-id: http://yate.null.ro/svn/yate/trunk@2924 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
marian 2009-11-11 13:00:09 +00:00
parent 413102c4c1
commit d3a451fcae
1 changed files with 3 additions and 2 deletions

View File

@ -1224,8 +1224,9 @@ public:
*/
inline XmlElement* pop() {
XmlElement* x = findFirstChild();
if (x)
m_children.removeChild(x,false);
if (!(x && x->completed()))
return 0;
m_children.removeChild(x,false);
return x;
}