syncml: use cutXML with str, not bytes
When cutting with bytes, we might cut in the middle of a multi-bytes character and later decoding it would cause an error. We could switch to sending bytes encoded to base64, because the limit would be more natural to be number of bytes, but just decoding and cutting the string is easier and in practice not so different. This bug was revealed by testERP5SyncML.TestERP5SyncML.test_28_PartialData with PYTHONHASHSEED 872 and test_28_PartialData with PYTHONHASHSEED 238 ( on python2 )
Showing
Please register or sign in to comment