summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2006-06-22 01:49:39 +0000
committerZac Medico <zmedico@gentoo.org>2006-06-22 01:49:39 +0000
commitd1c55a0758f558e00f5a695d24e8b19f319d09a9 (patch)
tree7db10cf5ba109b77c81f88af3075375823dfbf79
parent84578b13aaff961665895625f75d1fbba3620365 (diff)
downloadportage-d1c55a0758f558e00f5a695d24e8b19f319d09a9.tar.gz
portage-d1c55a0758f558e00f5a695d24e8b19f319d09a9.tar.bz2
portage-d1c55a0758f558e00f5a695d24e8b19f319d09a9.zip
Prevent and exception when PORT_LOGDIR is an empty string.
svn path=/main/trunk/; revision=3589
-rw-r--r--pym/portage.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/pym/portage.py b/pym/portage.py
index be9f8c2a8..63d5f5a9b 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -2720,9 +2720,12 @@ def prepare_build_dirs(myroot, mysettings, cleanup):
pass # ebuild.sh will create it
if "PORT_LOGDIR" in mysettings:
- logging_enabled = True
+ if mysettings["PORT_LOGDIR"] == "":
+ logging_enabled = False
+ else:
+ logging_enabled = True
- if not makedirs(mysettings["PORT_LOGDIR"]):
+ if logging_enabled and not makedirs(mysettings["PORT_LOGDIR"]):
writemsg("!!! Unable to create PORT_LOGDIR\n",
noiselevel=-1)
logging_enabled = False