From 06e5a2b4b03f1d4bb5b494547f3d7af7b5f58df6 Mon Sep 17 00:00:00 2001 From: Jeremy Katz Date: Thu, 2 Aug 2001 19:20:53 +0000 Subject: use rmrf instead of unlinking the logfiles if they already exist so that if they're directories, we don't traceback --- packages.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages.py b/packages.py index dbed16b24..d9655d196 100644 --- a/packages.py +++ b/packages.py @@ -488,14 +488,14 @@ def doInstall(method, id, intf, instPath): instLogName = instPath + logname try: - os.unlink (instLogName) + iutil.rmrf (instLogName) except OSError: pass instLog = open(instLogName, "w+") syslogname = "%s%s.syslog" % (instPath, logname) try: - os.unlink (syslogname) + iutil.rmrf (syslogname) except OSError: pass syslog.start (instPath, syslogname) -- cgit