[Yum-devel] bug in downloadPgks.

Menno Smits menno-yum at freshfoo.com
Tue Sep 12 07:15:26 UTC 2006


Hey Tim,

Thanks for the patch but I fixed it myself before I saw your email.

Menno

Tim Lauridsen wrote:
> The size check in downloadPkgs dont work and a keyError occours.
> 
> Here is a patch to fix it.
> 
> Tim
> 
> Scanned by the NetBox from NetBox Blue
> (http://netboxblue.com/)
> 
> 
> ------------------------------------------------------------------------
> 
> ### Eclipse Workspace Patch 1.0
> #P yum
> Index: yum/__init__.py
> ===================================================================
> RCS file: /cvsroot/yum/cvs/yum/yum/__init__.py,v
> retrieving revision 1.249
> diff -u -r1.249 __init__.py
> --- yum/__init__.py	8 Sep 2006 21:05:16 -0000	1.249
> +++ yum/__init__.py	10 Sep 2006 07:49:31 -0000
> @@ -647,8 +647,9 @@
>              i += 1
>              checkfunc = (self.verifyPkg, (po, 1), {})
>              stvfs = os.statvfs(po.repo.pkgdir)
> -            if stvfs[4] * stvfs[0] <= po.size:
> +            if stvfs[4] * stvfs[0] <= float(po.size):
>                  msg = "Insufficient space in download directory %s to download" % po.repo.pkgdir
> +                if not errors.has_key(po): errors[po] = []
>                  errors[po].append(msg)
>                  continue
>              
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Yum-devel mailing list
> Yum-devel at linux.duke.edu
> https://lists.dulug.duke.edu/mailman/listinfo/yum-devel




More information about the Yum-devel mailing list