Skip to content

Fix crashes when serializing non ascii characters to json#394

Open
MrS-ibra wants to merge 1 commit intoGeneralsOnlineDevelopmentTeam:mainfrom
MrS-ibra:fix/non-ascii-json-crash
Open

Fix crashes when serializing non ascii characters to json#394
MrS-ibra wants to merge 1 commit intoGeneralsOnlineDevelopmentTeam:mainfrom
MrS-ibra:fix/non-ascii-json-crash

Conversation

@MrS-ibra
Copy link
Member

@MrS-ibra MrS-ibra commented Mar 19, 2026

The game crashed when selecting maps or sending messages with non ascii characters in any of the online chats due to nlohmann::json's default error handler being set to strict, which throws an exception when serializing invalid UTF-8 bytes.
Changed the default error handler to error_handler_t::replace to prevent the crashes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant