Mercurial > p > roundup > code
comparison roundup/scripts/roundup_server.py @ 3279:6e7462bbafde
fix setgid typo [SF#1171346]
| author | Richard Jones <richard@users.sourceforge.net> |
|---|---|
| date | Wed, 13 Apr 2005 06:12:12 +0000 |
| parents | 3084b07ec266 |
| children | 87a017f50195 |
comparison
equal
deleted
inserted
replaced
| 3277:3084b07ec266 | 3279:6e7462bbafde |
|---|---|
| 15 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. | 15 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. |
| 16 # | 16 # |
| 17 | 17 |
| 18 """Command-line script that runs a server over roundup.cgi.client. | 18 """Command-line script that runs a server over roundup.cgi.client. |
| 19 | 19 |
| 20 $Id: roundup_server.py,v 1.78 2005-04-13 05:30:06 richard Exp $ | 20 $Id: roundup_server.py,v 1.79 2005-04-13 06:12:12 richard Exp $ |
| 21 """ | 21 """ |
| 22 __docformat__ = 'restructuredtext' | 22 __docformat__ = 'restructuredtext' |
| 23 | 23 |
| 24 import errno, cgi, getopt, os, socket, sys, traceback, urllib, time | 24 import errno, cgi, getopt, os, socket, sys, traceback, urllib, time |
| 25 import ConfigParser, BaseHTTPServer, SocketServer, StringIO | 25 import ConfigParser, BaseHTTPServer, SocketServer, StringIO |
| 261 return | 261 return |
| 262 if not hasattr(os, 'setgid'): | 262 if not hasattr(os, 'setgid'): |
| 263 return | 263 return |
| 264 | 264 |
| 265 # if root, setgid to the running user | 265 # if root, setgid to the running user |
| 266 if not os.getuid(): | 266 if os.getuid(): |
| 267 print _('WARNING: ignoring "-g" argument, not root') | 267 print _('WARNING: ignoring "-g" argument, not root') |
| 268 return | 268 return |
| 269 | 269 |
| 270 try: | 270 try: |
| 271 import grp | 271 import grp |
