1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Fix accelerate module on centos 5 by removing

unsupported string prefix in 2.4

http://docs.python.org/release/2.4/ref/strings.html
This is also ignored on later version of python 2
and is present only for python 3 conversion, as seen
on http://docs.python.org/2/reference/lexical_analysis.html#string-literals

Also see http://stackoverflow.com/questions/6269765/what-does-the-b-character-do-in-front-of-a-string-literal

Fix https://github.com/ansible/ansible/issues/4739
This commit is contained in:
Michael Scherer 2013-10-31 21:00:43 +01:00
parent affa703fcb
commit 8efe53eebb

View file

@ -197,7 +197,7 @@ class ThreadedTCPRequestHandler(SocketServer.BaseRequestHandler):
def recv_data(self):
header_len = 8 # size of a packed unsigned long long
data = b""
data = ""
vvvv("in recv_data(), waiting for the header")
while len(data) < header_len:
d = self.request.recv(header_len - len(data))