NaikSoftware / StompProtocolAndroid

STOMP protocol via WebSocket for Android
MIT License
597 stars 265 forks source link

Data is lost / modified if server sends binary data #192

Open andrewdittmer opened 3 years ago

andrewdittmer commented 3 years ago

If server sends binary data with content type application/octet-stream, this data can be lost / incomplete after being converted to a string.

Perhaps StompMessage could contain a bytearray field of the original data sent?

Steps to reproduce: Server sends binary data which includes signed int.

Expected outcome: There should be a way to get the data as originally sent

Actual result: in the subscribe callback, the correct data cannot be retrieved from the stompMessage payload due to character encoding.