Skip to content

Commit 00a9590

Browse files
committed
examples/http_client: Use read() instead of readall().
1 parent 59a1201 commit 00a9590

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/network/http_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def main(use_stream=False):
1919
# directly, but the line below is needed for CPython.
2020
s = s.makefile("rwb", 0)
2121
s.write(b"GET / HTTP/1.0\r\n\r\n")
22-
print(s.readall())
22+
print(s.read())
2323
else:
2424
s.send(b"GET / HTTP/1.0\r\n\r\n")
2525
print(s.recv(4096))

0 commit comments

Comments
 (0)