remove latest \n in bosh received messages (one is added when we send)
This commit is contained in:
parent
8514e51675
commit
d37d1e973f
|
@ -687,6 +687,9 @@ class NonBlockingHTTP(NonBlockingTCP):
|
||||||
httpbody - string with http body)
|
httpbody - string with http body)
|
||||||
'''
|
'''
|
||||||
message = message.replace('\r','')
|
message = message.replace('\r','')
|
||||||
|
# Remove latest \n
|
||||||
|
if message.endswith('\n'):
|
||||||
|
message = message[:-1]
|
||||||
(header, httpbody) = message.split('\n\n', 1)
|
(header, httpbody) = message.split('\n\n', 1)
|
||||||
header = header.split('\n')
|
header = header.split('\n')
|
||||||
statusline = header[0].split(' ', 2)
|
statusline = header[0].split(' ', 2)
|
||||||
|
|
Loading…
Reference in New Issue