X-Git-Url: http://www.project-moonshot.org/gitweb/?a=blobdiff_plain;f=samltest%2Finternal.h;h=2389848c9e70335e2973b7bceb5ea6eb68114124;hb=b59952455d0d04290fca1460a2a50b1cd84f0e27;hp=f1abd8872023189aab778be1cd2f0dce69445438;hpb=3fe2b35dc5b5866e3ce7bde70faab0815acfa5b6;p=shibboleth%2Fcpp-opensaml.git diff --git a/samltest/internal.h b/samltest/internal.h index f1abd88..2389848 100644 --- a/samltest/internal.h +++ b/samltest/internal.h @@ -105,10 +105,9 @@ protected: } void assertEquals(DOMDocument* expectedDOM, XMLObject* xmlObject, bool canMarshall=true) { - assertEquals("Marshalled DOM was not the same as the expected DOM", expectedDOM, xmlObject, canMarshall); - // Test a clone operation before destroying the original. xmlObject->releaseThisAndChildrenDOM(); - delete xmlObject->clone(); + auto_ptr cloned(xmlObject->clone()); + assertEquals("Marshalled DOM was not the same as the expected DOM", expectedDOM, cloned.get(), canMarshall); delete xmlObject; }