2 * Copyright 2010, Oliver Tappe, zooey@hirschkaefer.de
3 * All rights reserved. Distributed under the terms of the MIT License.
9 #include "LocaleBackend.h"
11 #include <PosixLanginfo.h>
14 using BPrivate::Libroot::gLocaleBackend
;
15 using BPrivate::Libroot::gPosixLanginfo
;
19 nl_langinfo(nl_item item
)
21 if (item
< 0 || item
>= _NL_LANGINFO_LAST
)
22 return const_cast<char*>("");
24 if (gLocaleBackend
!= NULL
)
25 return const_cast<char*>(gLocaleBackend
->GetLanginfo(item
));
27 return const_cast<char*>(gPosixLanginfo
[item
]);