[hackers] [scc] [libc] Add localeconv || Quentin Rameau

From: <git_AT_suckless.org>
Date: Tue, 21 Feb 2017 19:42:00 +0100 (CET)

commit fbacf733497678230358cc825ec86c3dd00f5f6c
Author: Quentin Rameau <quinq_AT_fifth.space>
AuthorDate: Tue Feb 21 18:33:13 2017 +0100
Commit: Quentin Rameau <quinq_AT_fifth.space>
CommitDate: Tue Feb 21 19:40:45 2017 +0100

    [libc] Add localeconv

diff --git a/libc/src/Makefile b/libc/src/Makefile
index 47225a2..4423a90 100644
--- a/libc/src/Makefile
+++ b/libc/src/Makefile
_AT_@ -7,7 +7,8 @@ LIBCOBJ = assert.o strcpy.o strcmp.o strlen.o strchr.o \
           memset.o memcpy.o memmove.o memcmp.o memchr.o \
           isalnum.o isalpha.o isascii.o isblank.o iscntrl.o isdigit.o \
           isgraph.o islower.o isprint.o ispunct.o isspace.o isupper.o \
- isxdigit.o toupper.o tolower.o setlocale.o
+ isxdigit.o toupper.o tolower.o setlocale.o \
+ localeconv.o
 
 all: libc.a
 
diff --git a/libc/src/localeconv.c b/libc/src/localeconv.c
new file mode 100644
index 0000000..52943e8
--- /dev/null
+++ b/libc/src/localeconv.c
_AT_@ -0,0 +1,13 @@
+#include <locale.h>
+#include <limits.h>
+
+struct lconv *
+localeconv(void)
+{
+ static struct lconv lc = { ".", "", "", "", "", "", "", "", "", "",
+ CHAR_MAX, CHAR_MAX, CHAR_MAX, CHAR_MAX,
+ CHAR_MAX, CHAR_MAX, CHAR_MAX, CHAR_MAX,
+ CHAR_MAX, CHAR_MAX, CHAR_MAX, CHAR_MAX,
+ CHAR_MAX, CHAR_MAX };
+ return &lc;
+}
Received on Tue Feb 21 2017 - 19:42:00 CET

This archive was generated by hypermail 2.3.0 : Tue Feb 21 2017 - 19:48:26 CET