From: Zac Medico Date: Sat, 31 Oct 2009 18:59:37 +0000 (-0000) Subject: Bug #291271 - Make vardbapi._bump_mtime() create category directories when X-Git-Tag: v2.2_rc48~7 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=35f78590d6b702f9cfbcacd77338b0c2382d18da;p=portage.git Bug #291271 - Make vardbapi._bump_mtime() create category directories when necessary. svn path=/main/trunk/; revision=14753 --- diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py index 049db6e40..db91be3d5 100644 --- a/pym/portage/dbapi/vartree.py +++ b/pym/portage/dbapi/vartree.py @@ -860,8 +860,11 @@ class vardbapi(dbapi): catdir = base + _os.sep + cat t = time.time() t = (t, t) - for x in (catdir, base): - os.utime(x, t) + try: + for x in (catdir, base): + os.utime(x, t) + except OSError: + os.makedirs(catdir) def cpv_exists(self, mykey): "Tells us whether an actual ebuild exists on disk (no masking)"