Home | Trees | Indices | Help |
|
---|
|
object --+ | MultipartWrapper
Wraps a file-like object, returning '' when Content-Length is reached.
The cgi module's logic for reading multipart MIME messages doesn't allow the parts to know when the Content-Length for the entire message has been reached, and doesn't allow for multipart-MIME messages that omit the trailing CRLF (Flash 8's FileReference.upload(url), for example, does this). The read_lines_to_outerboundary function gets stuck in a loop until the socket times out.
This rfile wrapper simply monitors the incoming stream. When a read is attempted past the Content-Length, it returns an empty string rather than timing out (of course, if the last read *overlaps* the C-L, you'll get the last bit of data up to C-L, and then the next read will return an empty string).
Instance Methods | |||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from |
Properties | |
Inherited from |
Method Details |
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Thu Jul 14 21:45:37 2011 | http://epydoc.sourceforge.net |