hgweb: adapt to socket._fileobject changes in Python 3
Differential Revision: https://phab.mercurial-scm.org/D2688
--- a/mercurial/hgweb/server.py Sun Mar 04 16:20:24 2018 -0500
+++ b/mercurial/hgweb/server.py Sun Mar 04 21:14:24 2018 -0500
@@ -257,8 +257,8 @@
def setup(self):
self.connection = self.request
- self.rfile = socket._fileobject(self.request, "rb", self.rbufsize)
- self.wfile = socket._fileobject(self.request, "wb", self.wbufsize)
+ self.rfile = self.request.makefile(r"rb", self.rbufsize)
+ self.wfile = self.request.makefile(r"wb", self.wbufsize)
try:
import threading