diff --git a/src/system/libroot/posix/locale/setlocale.c b/src/system/libroot/posix/locale/setlocale.c index 1717421bba..0bf9b26ce5 100644 --- a/src/system/libroot/posix/locale/setlocale.c +++ b/src/system/libroot/posix/locale/setlocale.c @@ -1,5 +1,5 @@ /* - * Copyright 2004-2006, Axel Dörfler, axeld@pinc-software.de. All rights reserved. + * Copyright 2004-2007, Axel Dörfler, axeld@pinc-software.de. All rights reserved. * Distributed under the terms of the MIT License. */ @@ -11,7 +11,7 @@ char * setlocale(int category, const char *locale) { - if (locale == NULL) + if (locale == NULL || !locale[0]) return "C"; // ToDo: this should check if liblocale.so is available and use its functions