From: richard Date: Tue, 12 Aug 2003 01:14:11 +0000 (+0000) Subject: logfile must be specified if pidfile is (sf bug 772820) X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=f64e0275b0de4071d8048753258cbbbec47d89f4;p=roundup.git logfile must be specified if pidfile is (sf bug 772820) git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1804 57a73879-2fb5-44c3-a270-3262357dd7e2 --- diff --git a/CHANGES.txt b/CHANGES.txt index abfaf8c..9659528 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -5,6 +5,7 @@ are given with the most recent entry first. - Fixed editing attributes on FileClass nodes. - Query editing now works correctly (sf bug 621248) - roundup-server now logs IP addresses by default (sf bug 778795) +- logfile must be specified if pidfile is (sf bug 772820) 2003-07-29 0.6.0b4 - plugged cross-site-scripting hole (thanks Jeff Epler) diff --git a/roundup/scripts/roundup_server.py b/roundup/scripts/roundup_server.py index e6dd124..1575f41 100644 --- a/roundup/scripts/roundup_server.py +++ b/roundup/scripts/roundup_server.py @@ -16,7 +16,7 @@ # """ HTTP Server that serves roundup. -$Id: roundup_server.py,v 1.25 2003-08-12 01:11:43 richard Exp $ +$Id: roundup_server.py,v 1.26 2003-08-12 01:14:11 richard Exp $ """ # python version check @@ -316,7 +316,7 @@ options: -l: sets a filename to log to (instead of stdout) -d: run the server in the background and on UN*X write the server's PID to the nominated file. Note: on Windows the PID argument is needed, - but ignored. + but ignored. The -l option *must* be specified if this option is. -N: log client machine names in access log instead of IP addresses (much slower) @@ -405,6 +405,9 @@ def run(): elif opt == '-h': usage() elif opt == '-N': RoundupRequestHandler.LOG_IPADDRESS = 0 + if pidfile and not logfile: + raise ValueError, _("logfile *must* be specified if pidfile is") + if hasattr(os, 'getuid'): # if root, setuid to the running user if not os.getuid() and user is not None: