summaryrefslogtreecommitdiff
path: root/libc/unistd/confstr.c
diff options
context:
space:
mode:
authorAustin Foxley <austinf@cetoncorp.com>2010-04-06 09:16:02 -0700
committerAustin Foxley <austinf@cetoncorp.com>2010-04-06 09:16:02 -0700
commite0a9623c6c30faf915b31358824aa2f8031df8b2 (patch)
tree4eb7f2cebc3a5448f197b5b485d7771963bf6cde /libc/unistd/confstr.c
parentf10d127d36ada5b202cdea521e61b05522beb192 (diff)
correctly quote version in confstr
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
Diffstat (limited to 'libc/unistd/confstr.c')
-rw-r--r--libc/unistd/confstr.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/libc/unistd/confstr.c b/libc/unistd/confstr.c
index 957ee4d27..8cd4ac59e 100644
--- a/libc/unistd/confstr.c
+++ b/libc/unistd/confstr.c
@@ -24,6 +24,7 @@
#define CS_PATH "/bin:/usr/bin"
+#define QUOTEME(x) #x
/* If BUF is not NULL and LEN > 0, fill in at most LEN - 1 bytes
of BUF with the value corresponding to NAME and zero-terminate BUF.
@@ -52,9 +53,9 @@ size_t confstr (int name, char *buf, size_t len)
string_len = sizeof("linuxthreads-x.xx");
# elif defined __UCLIBC_HAS_THREADS_NATIVE__
# define __NPTL_VERSION ("NPTL " \
- #__UCLIBC_MAJOR__ "." \
- #__UCLIBC_MINOR__ "." \
- #__UCLIBC_SUBLEVEL__)
+ QUOTEME(__UCLIBC_MAJOR__) "." \
+ QUOTEME(__UCLIBC_MINOR__) "." \
+ QUOTEME(__UCLIBC_SUBLEVEL__) )
string = __NPTL_VERSION;
string_len = sizeof(__NPTL_VERSION);
# endif