licq-im / licq

An instant messaging client for UNIX
http://www.licq.org/
16 stars 4 forks source link

Some received messages with national symbols are empty (in 1.7.1) #28

Closed asy972 closed 11 years ago

asy972 commented 11 years ago

Hello.

During operation with 1.7.1 I found that the messages from some clients displays empty if they contain Cyrillic characters.

displays empty from: Miranda IM 0.8.4 Unicode (ICQ Plus 0.3.10.5 alpha) QIP Infinium build 9030 RC4 (for Windows)

displays properly from: ICQ 7.6 build 5620 QIP 0.8.4.6 (beta) for Android

1.6 displays messages from Miranda and QIP/Windows properly also.

erijo commented 11 years ago

Can you please run licq with -d31 and post the output when you receive a message that don't display correctly.

asy972 commented 11 years ago

00:49:48.695 [DBG] icq: Packet (SRV, 253 bytes) received:
(10.1.1.139:54592 <- 64.12.30.99:5190)
0000: 2A 02 B1 DD 00 F7 00 04 00 07 00 00 95 9F F5 FC *............... 0010: B1 71 2E 51 E8 CC 00 00 00 02 08 35 33 34 35 34 .q.Q.......53454 0020: 30 36 36 00 00 00 07 00 01 00 02 00 51 00 06 00 066.........Q... 0030: 04 20 01 00 00 00 05 00 04 38 17 27 45 00 1D 00 . .......8.'E... 0040: 00 00 0F 00 04 00 00 41 2F 00 03 00 04 51 2E 30 .......A/....Q.0 0050: 84 00 37 00 04 00 00 00 00 00 05 00 69 00 00 B1 ..7.........i... 0060: 71 2E 51 E8 CC 00 00 09 46 13 49 4C 7F 11 D1 82 q.Q.....F.IL.... 0070: 22 44 45 53 54 00 00 00 0A 00 02 00 01 00 0F 00 "DEST........... 0080: 00 27 11 00 41 1B 00 08 00 00 00 00 00 00 00 00 .'..A........... 0090: 00 00 00 00 00 00 00 00 00 00 00 03 00 00 00 04 ................ 00A0: 3C 1D 0E 00 3C 1D 00 00 00 00 00 00 00 00 00 00 <...<........... 00B0: 00 00 01 00 00 00 00 01 04 00 F5 F0 FE 00 00 00 ................ 00C0: 00 00 FF FF FF 00 00 24 00 24 36 34 30 39 32 33 .......$.$640923 00D0: 65 61 2D 38 31 31 66 2D 31 31 65 32 2D 61 37 36 ea-811f-11e2-a76 00E0: 66 2D 62 37 61 63 33 33 37 35 62 32 34 37 00 0B f-b7ac3375b247.. 00F0: 00 00 00 28 00 02 00 01 00 13 00 01 63 ...(........c 00:49:48.696 [WAR] icq: Unable to encode from UTF-8 to CP1251.

The message received in 1251. It should not be attempt to encode from UTF-8...

flynd commented 11 years ago

Due to a typo the non-UTF8 messages were converted from UTF8 when they should be converted to UTF8 instead. The above commit should solve the problem. If not, please reopen the ticket.

asy972 commented 11 years ago

Thanks! It works.