Changeset 835
- Timestamp:
- 11/26/05 13:06:53
- Files:
-
- trunk/cherrypy/__init__.py (modified) (1 diff)
- trunk/cherrypy/_cphttptools.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/cherrypy/__init__.py
r809 r835 19 19 from cherrypy._cpthreadinglocal import local 20 20 21 # Create a threadlocal object to hold the request and response objects. 22 # In this way, we can easily dump those objects when we stop/start a 23 # new HTTP conversation. 21 # Create a threadlocal object to hold the request and response 22 # objects. In this way, we can easily dump those objects when 23 # we stop/start a new HTTP conversation, yet still refer to 24 # them as module-level globals in a thread-safe way. 24 25 serving = local() 25 26 trunk/cherrypy/_cphttptools.py
r833 r835 45 45 46 46 """ 47 self.requestLine = requestLine.strip() 48 self.headers = list(headers) 49 self.rfile = rfile 50 47 51 if cherrypy.profiler: 48 cherrypy.profiler.run(self._run , requestLine, headers, rfile)49 else: 50 self._run( requestLine, headers, rfile)52 cherrypy.profiler.run(self._run) 53 else: 54 self._run() 51 55 return cherrypy.response 52 56 53 def _run(self , requestLine, headers, rfile):57 def _run(self): 54 58 55 59 try: 56 self.headers = list(headers)57 60 self.headerMap = httptools.HeaderMap() 58 61 self.simpleCookie = Cookie.SimpleCookie() 59 self.rfile = rfile60 62 61 63 # This has to be done very early in the request process, 62 64 # because request.objectPath is used for config lookups 63 65 # right away. 64 self.processRequestLine( requestLine)66 self.processRequestLine() 65 67 66 68 try: … … 102 104 _cputil.getSpecialAttribute("_cpLogAccess")() 103 105 104 def processRequestLine(self , requestLine):105 self.requestLine = rl = requestLine.strip()106 def processRequestLine(self): 107 rl = self.requestLine 106 108 method, path, qs, proto = httptools.parseRequestLine(rl) 107 109 if path == "*":

