Allow setting the local to "C" (i.e. not changing it at all). This makes
programs happy, that do that unconditionally (e.g. some Perl test). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24334 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
6e4432bc6f
commit
32da50fafb
@ -6,14 +6,16 @@
|
||||
|
||||
#include <locale.h>
|
||||
#include <limits.h>
|
||||
#include <string.h>
|
||||
|
||||
|
||||
char *
|
||||
setlocale(int category, const char *locale)
|
||||
{
|
||||
if (locale == NULL || !locale[0])
|
||||
if (locale == NULL || !locale[0] || strcmp(locale, "C") == 0)
|
||||
return "C";
|
||||
|
||||
// ToDo: this should check if liblocale.so is available and use its functions
|
||||
// TODO: this should check if liblocale.so is available and use its
|
||||
// functions.
|
||||
return NULL;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user