Mailinglist Archive: zypp-commit (315 mails)
| < Previous | Next > |
[zypp-commit] r11141 - /trunk/libzypp/zypp/RepoManager.cc
- From: mlandres@xxxxxxxxxxxxxxxx
- Date: Wed, 24 Sep 2008 11:37:11 -0000
- Message-id: <20080924113711.E4E842FEAB@xxxxxxxxxxxxxxxx>
Author: mlandres
Date: Wed Sep 24 13:37:11 2008
New Revision: 11141
URL: http://svn.opensuse.org/viewcvs/zypp?rev=11141&view=rev
Log:
use non-throwing test for presence of Target
Modified:
trunk/libzypp/zypp/RepoManager.cc
Modified: trunk/libzypp/zypp/RepoManager.cc
URL:
http://svn.opensuse.org/viewcvs/zypp/trunk/libzypp/zypp/RepoManager.cc?rev=11141&r1=11140&r2=11141&view=diff
==============================================================================
--- trunk/libzypp/zypp/RepoManager.cc (original)
+++ trunk/libzypp/zypp/RepoManager.cc Wed Sep 24 13:37:11 2008
@@ -109,11 +109,12 @@
knownReposPath = Pathname::assertprefix( root_r,
ZConfig::instance().knownReposPath() );
knownServicesPath = Pathname::assertprefix( root_r,
ZConfig::instance().knownServicesPath() );
probe = ZConfig::instance().repo_add_probe();
- try
+
+ if ( getZYpp()->getTarget() )
{
servicesTargetDistro = getZYpp()->target()->targetDistribution();
}
- catch (const Exception & e)
+ else
{
DBG << "Target not initialized, using an empty servicesTargetDistro." <<
endl;
}
--
To unsubscribe, e-mail: zypp-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-commit+help@xxxxxxxxxxxx
Date: Wed Sep 24 13:37:11 2008
New Revision: 11141
URL: http://svn.opensuse.org/viewcvs/zypp?rev=11141&view=rev
Log:
use non-throwing test for presence of Target
Modified:
trunk/libzypp/zypp/RepoManager.cc
Modified: trunk/libzypp/zypp/RepoManager.cc
URL:
http://svn.opensuse.org/viewcvs/zypp/trunk/libzypp/zypp/RepoManager.cc?rev=11141&r1=11140&r2=11141&view=diff
==============================================================================
--- trunk/libzypp/zypp/RepoManager.cc (original)
+++ trunk/libzypp/zypp/RepoManager.cc Wed Sep 24 13:37:11 2008
@@ -109,11 +109,12 @@
knownReposPath = Pathname::assertprefix( root_r,
ZConfig::instance().knownReposPath() );
knownServicesPath = Pathname::assertprefix( root_r,
ZConfig::instance().knownServicesPath() );
probe = ZConfig::instance().repo_add_probe();
- try
+
+ if ( getZYpp()->getTarget() )
{
servicesTargetDistro = getZYpp()->target()->targetDistribution();
}
- catch (const Exception & e)
+ else
{
DBG << "Target not initialized, using an empty servicesTargetDistro." <<
endl;
}
--
To unsubscribe, e-mail: zypp-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-commit+help@xxxxxxxxxxxx
| < Previous | Next > |