*** /cygdrive/c/Python23/Lib/SimpleHTTPServer.py Sat Jun 1 16:18:46 2002 --- SimpleHTTPServer.py Mon Nov 10 21:30:14 2003 *************** class SimpleHTTPRequestHandler(BaseHTTPS *** 71,82 **** else: return self.list_directory(path) ctype = self.guess_type(path) - if ctype.startswith('text/'): - mode = 'r' - else: - mode = 'rb' try: ! f = open(path, mode) except IOError: self.send_error(404, "File not found") return None --- 71,78 ---- else: return self.list_directory(path) ctype = self.guess_type(path) try: ! f = open(path, 'rb') # always read in binary mode except IOError: self.send_error(404, "File not found") return None