Update of /cvsroot/tmda/tmda/contrib/cgi
In directory sc8-pr-cvs1:/tmp/cvs-serv21299
Modified Files:
CgiUtil.py
Log Message:
Switched Fatal routine over to use our new environment variable TMDA_CGI_MODE
instead of "figuring out" which mode we're in.
Index: CgiUtil.py
===================================================================
RCS file: /cvsroot/tmda/tmda/contrib/cgi/CgiUtil.py,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- CgiUtil.py 30 Nov 2002 18:11:57 -0000 1.3
+++ CgiUtil.py 6 Dec 2002 17:19:06 -0000 1.4
@@ -57,13 +57,6 @@
return "%s file <tt>%s</tt>, permissions %s" % (Desc, Filename, Perm)
def TermError(Err, Cause, Failed, Other, Recommend):
- if os.geteuid():
- if os.access(os.environ["HOME"], os.W_OK):
- Mode = "single-user"
- else:
- Mode = "no-su"
- else:
- Mode = "system-wide"
print """Expires: Mon, 26 Jul 1997 05:00:00 GMT
Last-Modified: %s GMT
Cache-Control: no-cache, must-revalidate
@@ -101,6 +94,7 @@
</tr>
</table>
</body>
-</html>""" % (time.strftime("%a, %d %b %Y %H:%M:%S"), Err, Cause, Mode, Failed,
- os.geteuid(), os.getegid(), Other, Recommend)
+</html>""" % (time.strftime("%a, %d %b %Y %H:%M:%S"), Err, Cause,
+ os.environ["TMDA_CGI_MODE"], Failed, os.geteuid(), os.getegid(), Other,
+ Recommend)
sys.exit(0)
_______________________________________
tmda-cvs mailing list
http://tmda.net/lists/listinfo/tmda-cvs