return on multiple calls to initTarget()
authorKlaus Kaempf <kkaempf@suse.de>
Thu, 23 Feb 2006 20:44:31 +0000 (20:44 +0000)
committerKlaus Kaempf <kkaempf@suse.de>
Thu, 23 Feb 2006 20:44:31 +0000 (20:44 +0000)
zypp/zypp_detail/ZYppImpl.cc

index 89a2071..fa8739c 100644 (file)
@@ -104,8 +104,11 @@ namespace zypp
 
     void ZYppImpl::initTarget(const Pathname & root, bool commit_only)
     {
-      if (_target)
-       _target = Target_Ptr();
+      if (_target) {
+       WAR << "Repeated call to initTarget()" << endl;
+        return;
+      }
+
       _target = new Target(root);
       if (!commit_only)
       {