From b449f5df29848097b12e161df5d50ceed03a0517 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sat, 3 Sep 2011 16:17:04 -0700 Subject: [PATCH] elog/mod_save: join /var/log with os.sep too --- pym/portage/elog/mod_save.py | 3 ++- pym/portage/elog/mod_save_summary.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/pym/portage/elog/mod_save.py b/pym/portage/elog/mod_save.py index bfccd7739..c69f4a3cf 100644 --- a/pym/portage/elog/mod_save.py +++ b/pym/portage/elog/mod_save.py @@ -18,7 +18,8 @@ def process(mysettings, key, logentries, fulltext): if mysettings.get("PORT_LOGDIR"): logdir = normalize_path(mysettings["PORT_LOGDIR"]) else: - logdir = os.path.join(mysettings["EPREFIX"], "var", "log", "portage") + logdir = os.path.join(os.sep, mysettings["EPREFIX"].lstrip(os.sep), + "var", "log", "portage") if not os.path.isdir(logdir): # Only initialize group/mode if the directory doesn't diff --git a/pym/portage/elog/mod_save_summary.py b/pym/portage/elog/mod_save_summary.py index 3196d43b3..347f66e6e 100644 --- a/pym/portage/elog/mod_save_summary.py +++ b/pym/portage/elog/mod_save_summary.py @@ -18,7 +18,8 @@ def process(mysettings, key, logentries, fulltext): if mysettings.get("PORT_LOGDIR"): logdir = normalize_path(mysettings["PORT_LOGDIR"]) else: - logdir = os.path.join(mysettings["EPREFIX"], "var", "log", "portage") + logdir = os.path.join(os.sep, mysettings["EPREFIX"].lstrip(os.sep), + "var", "log", "portage") if not os.path.isdir(logdir): # Only initialize group/mode if the directory doesn't -- 2.26.2