From a32312cecc88662c13b724b9c6f2f641c1b72822 Mon Sep 17 00:00:00 2001 From: Thomas Kriechbaumer Date: Sat, 16 Jul 2016 13:54:17 +0200 Subject: fix-1366 --- netlib/http/http1/read.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'netlib/http/http1') diff --git a/netlib/http/http1/read.py b/netlib/http/http1/read.py index a4c341fd..70fffbd4 100644 --- a/netlib/http/http1/read.py +++ b/netlib/http/http1/read.py @@ -244,7 +244,7 @@ def _read_request_line(rfile): raise exceptions.HttpReadDisconnect("Client disconnected") try: - method, path, http_version = line.split(b" ") + method, path, http_version = line.split() if path == b"*" or path.startswith(b"/"): form = "relative" @@ -291,8 +291,7 @@ def _read_response_line(rfile): raise exceptions.HttpReadDisconnect("Server disconnected") try: - - parts = line.split(b" ", 2) + parts = line.split(None, 2) if len(parts) == 2: # handle missing message gracefully parts.append(b"") -- cgit v1.2.3