2010-04-27 Danny Smith <dannysmith@users.sourceforge.net>
* mingwex/mb_wc_common.h (get_codepage): Revert change of 2006-09-19.
This commit is contained in:
parent
8f01c77516
commit
5f7eee9ec9
@ -1,3 +1,7 @@
|
||||
2010-04-27 Danny Smith <dannysmith@users.sourceforge.net>
|
||||
|
||||
* mingwex/mb_wc_common.h (get_codepage): Revert change of 2006-09-19.
|
||||
|
||||
2010-03-06 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
|
||||
|
||||
* include/_mingw.h: Increment version to 3.18.
|
||||
|
@ -1,7 +1,13 @@
|
||||
__declspec(dllimport) unsigned int __lc_codepage;
|
||||
#include <locale.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
static inline
|
||||
unsigned int get_codepage (void)
|
||||
{
|
||||
return __lc_codepage;
|
||||
/* locale :: "lang[_country[.code_page]]" | ".code_page" */
|
||||
char * cp_string;
|
||||
if ((cp_string = strchr (setlocale(LC_CTYPE, NULL), '.')))
|
||||
return ((unsigned) atoi (cp_string + 1));
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user