New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PacketEncoder corrupts UTF-8 message #157
Comments
Hello,
|
@evgeny-pasynkov hi! |
@mrniko What do you mean by "UTF-8 for sources"? Is it default encoding for JVM process? If yes, then it isn't a good solution - I don't want my software to depend on server locale :) Actually, converting my string to ISO_8859_1 damages it, so client cannot restore it further. |
@Maypeur your solution is tautology :) It is simply equivalent to "buf.writeBytes(b)" |
@evgeny-pasynkov maybe ! I let it because there was a problem with websocket and accent ! |
@evgeny-pasynkov could you purpose a better solution for this problem? |
@mrniko Could you point please to the mentioned websockets bug? Why not to simplify all this stuff to "buf.writeBytes(b)"? |
to avoid encoding problem |
What problems? In the code comment, you've mentioned the websockets bug. Which one? BTW, socket.io had some UTF-8 encoding problems, they claimed to be fixed in socket.io 1.1.0 |
@evgeny-pasynkov it is for #137 , using new socket.io.client 1.1.0 and socket.io 1.7.3-SNAPSHOT make problem on UTF-8 characters, but with client 1.0.6 and 1.7.3-SNAPSHOT it's working, so now the bug is corrected in client maybe PacketEncoder need to be adapted. Only @mrniko can say what to do now ! |
oh! i think to release next 1.7.4 version with this fix so it will be 1.1.0+ compatible only, ok? |
For me it is ok. |
Since pre 1.1.0 versions have this major bug i think it must ! |
please check |
The problem is fixed for my scenarios. Thank you! |
@Maypeur did you happy too? |
UTF-8 is now correct, but i'm searching why sometimes the memory gow up and never decrease even if i got only 5 users ! |
@Maypeur take a look at memory dump |
Hi,
Using SocketIOClient.send("русский"), I receive on client string "Ñ�Ñ�Ñ�Ñ�кий"
I think that the problem is in PacketEncoder lines 272-274:
the string gets corrupted when converting it with ISO_8859_1 charset, and then it is sent corrupted
The text was updated successfully, but these errors were encountered: