Bug #1365

UTF-8 encoding problem

Added by eagle_cz about 1 month ago. Updated 22 days ago.

Status:Fixed% Done:

100%

Priority:ImmediateSpent time:-
Assignee:-
Category:Mod generic
Target version:2.77
OS: Arch:

Description

when some players with special chars in nickname saying something on the main chat, then we getting this errors below in etconsole.log:

44342750 ^7^b°^xP^yund^xA^b°^7: ^2reee
44342800 WARNING: bad command byte for client 20
44342800 WARNING: bad command byte for client 20
44342800 WARNING: bad command byte for client 9
44342800 WARNING: bad command byte for client 20
44342800 WARNING: bad command byte for client 9
44342800 WARNING: bad command byte for client 34
44342850 WARNING: bad command byte for client 9
44342850 WARNING: bad command byte for client 20
44342850 WARNING: bad command byte for client 34
44342850 WARNING: bad command byte for client 20
44342850 WARNING: bad command byte for client 9
44342850 WARNING: bad command byte for client 34
44342850 WARNING: bad command byte for client 9
44342850 WARNING: bad command byte for client 20
44342850 WARNING: bad command byte for client 34
44342850 WARNING: bad command byte for client 9
44342850 WARNING: bad command byte for client 20
44342850 WARNING: bad command byte for client 34
44342850 WARNING: bad command byte for client 20
44342850 WARNING: bad command byte for client 9
44342850 WARNING: bad command byte for client 34
44342900 WARNING: bad command byte for client 9
44342900 WARNING: bad command byte for client 34
44342900 WARNING: bad command byte for client 20
44342900 WARNING: bad command byte for client 9
44342900 WARNING: bad command byte for client 20
44342900 WARNING: bad command byte for client 34
44342900 WARNING: bad command byte for client 9
44342900 WARNING: bad command byte for client 34
44342900 WARNING: bad command byte for client 20

65307100 Userinfo: \cg_uinfo\6 0 100\g_password\none\cl_guid\5D9C7AE389E3C1D2956B3C9648553154\password\84\name^b°^xP^yund^xA^b°\snaps\20\rate\35000\cl_wwwDownload\1\cg_allowGeoIP\1\ip\87.122.245.238:27960
65307100 broadcast: print "^7^b°^xP^yund^xA^b°^7 entered the game\n"

and ppl reported lags/freeze and other problems when this happened.


Related issues

Related to ET: Legacy Development - Bug #1111: Improve console language support New 21.09.2018
Related to ET: Legacy Development - Task #1377: Drop cg_etVersion check on server side New 28.12.2019
Related to ET: Legacy Development - Bug #1245: Bad command byte for client warning New 07.04.2019

Associated revisions

Revision 0e27d998
Added by RaFaL about 1 month ago

qcommon: fix possible segfault, when name was set with special characters this was causing game to crash at starup, refs #1365

Revision a9ea5f1e
Added by RaFaL about 1 month ago

Revert "qcommon: fix possible segfault, when name was set with special characters this was causing game to crash at starup, refs #1365"

This reverts commit 0e27d998d9cd21fc1fde35ec8d8cc6325c5d5d05.

Revision 379fcdec
Added by RaFaL about 1 month ago

qcommon: better solution for fixing possible segfault error. Some clean up, refs #1365

Revision a6c09688
Added by ryven about 1 month ago

general: implement conditional extended charset strip, refs #1111

  • Added facilities to conditionally strip >= 0x80 chars from the
    string commands based on available engine version information.
  • Any mod can issue unstripped commands, engine will intelligently
    handle these on both client and server sides, stripping chars from
    commands when necessary.
  • Fixed issue where vanilla clients were receiving unstripped commands from the
    etlegacy server if legacy mod was in use, leading to incorrect packets and
    user movements encoding.

History

#1 Updated by Spyhawk about 1 month ago

  • Subject changed from encoding problem to UTF-8 encoding problem
  • Category changed from Server to Mod generic
  • Status changed from New to Confirmed
  • Priority changed from High to Immediate
  • OS deleted (Linux)
  • Arch deleted (64-bit)

I can confirm some kind of microfreeze when playing with player °Punda° on server. When he disconnected, the game suddenly felt much smoother.

A few observations:
  • Players using 2.60b client reported the quite a few issues not present when using Legacy client
  • Some microfreeze when using Legacy client (I guess, when other 2.60b clients are present)
  • The special characters "°" didn’t appear in the crosshair label (cleanname) when aiming at the player (only "Punda" was displayed). The label with the colored label name and when spectating was however correct, displaying "°Punda°". Q_CleanStr actually remove special characters.

#2 Updated by Spyhawk about 1 month ago

  • Related to Bug #1111: Improve console language support added

#3 Updated by Spyhawk about 1 month ago

  • Status changed from Confirmed to In Progress
  • % Done changed from 0 to 90
  • In the near future, we still can drop cg_etVersion check on server side, and solely rely on etVersion set by the newest client. We however need to release the new client first (2.77). Tracked in #1377.

#4 Updated by Spyhawk 22 days ago

  • Related to Task #1377: Drop cg_etVersion check on server side added

#5 Updated by Spyhawk 22 days ago

  • Status changed from In Progress to Fixed
  • % Done changed from 90 to 100

#6 Updated by Spyhawk 21 days ago

  • Related to Bug #1245: Bad command byte for client warning added

Also available in: Atom PDF