0024645: Pointer to the last is wrong for a tree node
[occt.git] / src / TDataStd / TDataStd_TreeNode.cxx
index de47e20..2010048 100644 (file)
@@ -226,7 +226,7 @@ Standard_Boolean TDataStd_TreeNode::Remove ()
   }
 
   if (Father()->HasFirst()) {
-    if (Handle(TDataStd_TreeNode)::DownCast(this) == Father()->First()) {
+    if (this == Father()->First().operator->()) {
       if (HasNext()) {
            Father()->SetFirst(Next());
       }