[Yum-devel] [PATCH] Copy quick en/dis able to repos when repo is added
James Antill
james at fedoraproject.org
Tue Jul 21 15:33:48 UTC 2009
On Tue, 2009-07-21 at 10:44 -0400, Seth Vidal wrote:
>
> On Tue, 21 Jul 2009, James Antill wrote:
>
> > ---
> > yum/repos.py | 1 +
> > 1 files changed, 1 insertions(+), 0 deletions(-)
> >
> > diff --git a/yum/repos.py b/yum/repos.py
> > index ac3e197..32d3426 100644
> > --- a/yum/repos.py
> > +++ b/yum/repos.py
> > @@ -97,6 +97,7 @@ class RepoStorage:
> > raise Errors.DuplicateRepoError, 'Repository %s is listed more than once in the configuration' % (repoobj.id)
> > self.repos[repoobj.id] = repoobj
> > if hasattr(repoobj, 'quick_enable_disable'):
> > + self.quick_enable_disable.update(repoobj.quick_enable_disable)
> > repoobj.quick_enable_disable = self.quick_enable_disable
> > else:
> > self._cache_enabled_repos = None 1.6.2.5
>
> why are we setting repoobj.quick_enable_disable if we just checked if it
> already has it? Does the update() call not update all references to it?
We check to see if it has it, mainly so we can say the caching won't
work if it isn't there (weird repo. objects that don't inherit from
Repository class) ... we then reset it so it sharing the dictionary with
the containing RepoStorage.
--
James Antill <james at fedoraproject.org>
Fedora
More information about the Yum-devel
mailing list