- removed unused code, fixed compilation
authorJan Kupec <jkupec@suse.cz>
Fri, 7 Mar 2008 15:13:46 +0000 (15:13 +0000)
committerJan Kupec <jkupec@suse.cz>
Fri, 7 Mar 2008 15:13:46 +0000 (15:13 +0000)
src/zypper-repos.cc
src/zypper.cc

index f89d152..fecfe57 100644 (file)
@@ -1273,7 +1273,6 @@ ostream& operator << (ostream& s, const vector<T>& v) {
 void remove_repo(Zypper & zypper, const RepoInfo & repoinfo)
 {
   RepoManager manager(zypper.globalOpts().rm_options);
-  bool found = true;
   manager.removeRepository(repoinfo);
   zypper.out().info(boost::str(
     format(_("Repository '%s' has been removed.")) % repoinfo.name()));
index e68021e..450749d 100644 (file)
@@ -1589,12 +1589,8 @@ void Zypper::doCommand()
     }
 
     for (std::list<RepoInfo>::const_iterator it = repo_to_remove.begin();
-      it!=repo_to_remove.end();++it)
-    {
-      if (!remove_repo(*this,*it))
-       ERR << "Repository '" << it->alias() << "' found but cound not be"
-           " removed with root privileges. Should not happen." << endl;
-    }
+         it!=repo_to_remove.end();++it)
+      remove_repo(*this,*it);
 
     return;
   }