setlocale.c - scc - simple c99 compiler
HTML git clone git://git.simple-cc.org/scc
DIR Log
DIR Files
DIR Refs
DIR Submodules
DIR README
DIR LICENSE
---
setlocale.c (266B)
---
1 #include <locale.h>
2
3 #undef setlocale
4
5 char *
6 setlocale(int category, const char *locale)
7 {
8 if (category > LC_TIME || category < LC_ALL)
9 return NULL;
10 if (!locale
11 || locale[0] == '\0'
12 || locale[0] == 'C' && locale[1] == '\0') {
13 return "C";
14 }
15 return NULL;
16 }