summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2006-09-17 20:32:15 +0000
committerZac Medico <zmedico@gentoo.org>2006-09-17 20:32:15 +0000
commita67949d1f2c4462c61d37bbea29e872a13de3b62 (patch)
tree2ed148fe33d74de335d2712e753406376c94fc5e
parent17c6ae61f8bb71c4498d2a1d0110278230c587cb (diff)
downloadportage-a67949d1f2c4462c61d37bbea29e872a13de3b62.tar.gz
portage-a67949d1f2c4462c61d37bbea29e872a13de3b62.tar.bz2
portage-a67949d1f2c4462c61d37bbea29e872a13de3b62.zip
Use mtimedb.filename == None to disable mtimedb writes (instead of /dev/null).
svn path=/main/trunk/; revision=4468
-rwxr-xr-xbin/emerge2
-rw-r--r--pym/portage.py2
2 files changed, 3 insertions, 1 deletions
diff --git a/bin/emerge b/bin/emerge
index 05059aa92..95d41bf9e 100755
--- a/bin/emerge
+++ b/bin/emerge
@@ -3537,7 +3537,7 @@ def action_build(settings, trees, mtimedb,
if "--fetchonly" in myopts:
""" parallel-fetch uses --resume --fetchonly and we don't want
it to write the mtimedb"""
- mtimedb.filename = "/dev/null"
+ mtimedb.filename = None
mergetask.merge(mtimedb["resume"]["mergelist"], favorites, mtimedb)
else:
if "resume" in mtimedb and \
diff --git a/pym/portage.py b/pym/portage.py
index 775fc4385..551b4441b 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -6732,6 +6732,8 @@ class MtimeDB(dict):
self._clean_data = copy.deepcopy(d)
def commit(self):
+ if not self.filename:
+ return
d = {}
d.update(self)
# Only commit if the internal state has changed.