From: Michael Andres Date: Thu, 18 Sep 2008 14:14:27 +0000 (+0000) Subject: Use service alias as namespace for its repositories aliases. X-Git-Tag: 6.6.0~500 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=32c8cb5332dcfc97c93c8b905a821b9da8b9ca1b;p=platform%2Fupstream%2Flibzypp.git Use service alias as namespace for its repositories aliases. --- diff --git a/package/libzypp.changes b/package/libzypp.changes index 8f24e8bc3..2d6baca07 100644 --- a/package/libzypp.changes +++ b/package/libzypp.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Sep 18 16:11:23 CEST 2008 - ma@suse.de + +- Use service alias as namespace for it's repositories aliases. +- revision 11097 + ------------------------------------------------------------------- Thu Sep 18 12:45:25 CEST 2008 - jkupec@suse.cz diff --git a/zypp/RepoManager.cc b/zypp/RepoManager.cc index 1ebd637df..d9fc1f15b 100644 --- a/zypp/RepoManager.cc +++ b/zypp/RepoManager.cc @@ -121,7 +121,7 @@ namespace zypp { DBG << "Target not initialized, using an empty servicesTargetDistro." << endl; } - + rootDir = root_r; } @@ -1238,7 +1238,7 @@ namespace zypp for_(urlit, tosave.baseUrlsBegin(), tosave.baseUrlsEnd()) if (!urlit->getPassword().empty() && !urlit->getUsername().empty()) //! \todo use a method calling UI callbacks to ask where to save creds? - cm.saveInUser(media::AuthData(*urlit)); + cm.saveInUser(media::AuthData(*urlit)); } progress.toMax(); @@ -1672,6 +1672,9 @@ namespace zypp it->setPath(""); } + // Prepend service alias: + it->setAlias( str::form( "%s: %s", service.alias().c_str(), it->alias().c_str() ) ); + // use the same credentials as the service if (!serviceCredParam.empty()) url.setQueryParam("credentials", serviceCredParam); @@ -1732,7 +1735,7 @@ namespace zypp // exists outside this service. Maybe forcefully re-alias // the existing repo? addRepository( *it ); - + // save repo credentials } else @@ -1746,7 +1749,7 @@ namespace zypp oldRepoModified = true; } -#warning also check changed URL due to PATH/URL change in service, but ignore ?credentials param! +#warning also check changed URL due to PATH/URL change in service, but ignore ?credentials param! // save if modified: if ( oldRepoModified ) { diff --git a/zypp/ServiceInfo.cc b/zypp/ServiceInfo.cc index f0c04e23d..75f2eb849 100644 --- a/zypp/ServiceInfo.cc +++ b/zypp/ServiceInfo.cc @@ -16,7 +16,6 @@ #include "zypp/parser/xml/XmlEscape.h" #include "zypp/RepoInfo.h" -#include "zypp/parser/RepoindexFileReader.h" #include "zypp/repo/RepoInfoBaseImpl.h" #include "zypp/ServiceInfo.h"