[CONC-324] Wrong codepage numbers for some collations Created: 2018-04-19  Updated: 2018-04-24  Resolved: 2018-04-24

Status: Closed
Project: MariaDB Connector/C
Component/s: None
Affects Version/s: None
Fix Version/s: 3.0.4

Type: Bug Priority: Major
Reporter: Lawrin Novitsky Assignee: Lawrin Novitsky
Resolution: Fixed Votes: 0
Labels: None


 Description   

According to https://msdn.microsoft.com/en-us/library/windows/desktop/dd317756(v=vs.85).aspx mariadb_compiled_charsets array contains wrong data for codepage field for some collations. latin1 being probably most important.

Also for "auto" charset detection on Windows(mariadb_get_charset_by_name("auto")) I guess it's better to always use GetACP(), and not GetConsoleCP() in case of GetConsoleWindow(). At least from c/odbc point of view. Since GetConsoleCP() returns "OEM" codepage(usually 437 in US/Europe) and not default ANSI codepage(1252 in same places)

Suggested fix: https://github.com/MariaDB/mariadb-connector-c/pull/47



 Comments   
Comment by Lawrin Novitsky [ 2018-04-24 ]

The pull request has been merged, thus I am closing the report.
georg It's going into 3.0.4, right?

Generated at Thu Feb 08 03:04:29 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.