From d1c55a0758f558e00f5a695d24e8b19f319d09a9 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Thu, 22 Jun 2006 01:49:39 +0000 Subject: [PATCH] Prevent and exception when PORT_LOGDIR is an empty string. svn path=/main/trunk/; revision=3589 --- pym/portage.py | 7 +++++-- 1 file 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 -- 2.26.2