(self)
| 804 | disable_nagle_algorithm = False |
| 805 | |
| 806 | def setup(self): |
| 807 | self.connection = self.request |
| 808 | if self.timeout is not None: |
| 809 | self.connection.settimeout(self.timeout) |
| 810 | if self.disable_nagle_algorithm: |
| 811 | self.connection.setsockopt(socket.IPPROTO_TCP, |
| 812 | socket.TCP_NODELAY, True) |
| 813 | self.rfile = self.connection.makefile('rb', self.rbufsize) |
| 814 | if self.wbufsize == 0: |
| 815 | self.wfile = _SocketWriter(self.connection) |
| 816 | else: |
| 817 | self.wfile = self.connection.makefile('wb', self.wbufsize) |
| 818 | |
| 819 | def finish(self): |
| 820 | if not self.wfile.closed: |
nothing calls this directly
no test coverage detected