diff options
-rw-r--r-- | pym/portage/dbapi/vartree.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py index e9b183ec9..08263d6d3 100644 --- a/pym/portage/dbapi/vartree.py +++ b/pym/portage/dbapi/vartree.py @@ -1731,11 +1731,13 @@ class dblink(object): if self._scheduler is None: writemsg_level(msg, level=level, noiselevel=noiselevel) else: - log_path = self.settings.get("PORTAGE_LOG_FILE") + log_path = None + if self.settings.get("PORTAGE_BACKGROUND") != "subprocess": + log_path = self.settings.get("PORTAGE_LOG_FILE") background = self.settings.get("PORTAGE_BACKGROUND") == "1" - if log_path is None: - if not (background and level < logging.WARN): + if background and log_path is None: + if level >= logging.WARN: writemsg_level(msg, level=level, noiselevel=noiselevel) else: self._scheduler.output(msg, |