]> granicus.if.org Git - python/commitdiff
Get rid of nobody_uid() and import pwd -- not used here.
authorGuido van Rossum <guido@python.org>
Wed, 4 Sep 1996 23:42:04 +0000 (23:42 +0000)
committerGuido van Rossum <guido@python.org>
Wed, 4 Sep 1996 23:42:04 +0000 (23:42 +0000)
Lib/SimpleHTTPServer.py

index dd3107abc6faf1bad7172896c0e17d00e84c9d7a..ac3e38411593bac8cda93329448150e3fef1df0c 100644 (file)
@@ -10,7 +10,6 @@ __version__ = "0.3"
 
 
 import os
-import pwd
 import sys
 import time
 import socket
@@ -20,17 +19,6 @@ import SocketServer
 import BaseHTTPServer
 
 
-def nobody_uid():
-    """Internal routine to get nobody's uid"""
-    try:
-       nobody = pwd.getpwnam('nobody')[2]
-    except pwd.error:
-       nobody = 1 + max(map(lambda x: x[2], pwd.getpwall()))
-    return nobody
-
-nobody = nobody_uid()
-
-
 class SimpleHTTPRequestHandler(BaseHTTPServer.BaseHTTPRequestHandler):
 
     """Simple HTTP request handler with GET and HEAD commands.