aboutsummaryrefslogtreecommitdiffstats
path: root/libc
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2012-10-15 17:34:08 -0700
committerGerrit Code Review <noreply-gerritcodereview@google.com>2012-10-15 17:34:13 -0700
commita9944cfe9e152ca46afb0a77300ec5a2a1a24e64 (patch)
treed80d0045d50a9c5c775dbfb574f0635520ab104c /libc
parentfcf901d5c0924a71a1405a2535051663281da048 (diff)
parentf8a2c51bf3b85bf86bff905dd1232299d333dafe (diff)
downloadandroid_bionic-a9944cfe9e152ca46afb0a77300ec5a2a1a24e64.tar.gz
android_bionic-a9944cfe9e152ca46afb0a77300ec5a2a1a24e64.tar.bz2
android_bionic-a9944cfe9e152ca46afb0a77300ec5a2a1a24e64.zip
Merge "LONG_LONG_MIN/MAX: Move declarations to <limits.h>"
Diffstat (limited to 'libc')
-rw-r--r--libc/include/limits.h16
-rw-r--r--libc/include/pthread.h5
2 files changed, 16 insertions, 5 deletions
diff --git a/libc/include/limits.h b/libc/include/limits.h
index d691a8f01..b9d435450 100644
--- a/libc/include/limits.h
+++ b/libc/include/limits.h
@@ -89,6 +89,22 @@
#include <sys/syslimits.h>
#endif
+/* GLibc compatibility definitions.
+ Note that these are defined by GCC's <limits.h>
+ only when __GNU_LIBRARY__ is defined, i.e. when
+ targetting GLibc. */
+#ifndef LONG_LONG_MIN
+#define LONG_LONG_MIN LLONG_MIN
+#endif
+
+#ifndef LONG_LONG_MAX
+#define LONG_LONG_MAX LLONG_MAX
+#endif
+
+#ifndef ULONG_LONG_MAX
+#define ULONG_LONG_MAX ULLONG_MAX
+#endif
+
#ifndef PAGESIZE
#include <asm/page.h>
#define PAGESIZE PAGE_SIZE
diff --git a/libc/include/pthread.h b/libc/include/pthread.h
index 2015ac08a..ef6b80e75 100644
--- a/libc/include/pthread.h
+++ b/libc/include/pthread.h
@@ -310,9 +310,4 @@ extern void __pthread_cleanup_pop(__pthread_cleanup_t* c,
} /* extern "C" */
#endif
-/************ TO FIX ************/
-
-#define LONG_LONG_MAX __LONG_LONG_MAX__
-#define LONG_LONG_MIN (-__LONG_LONG_MAX__ - 1)
-
#endif /* _PTHREAD_H_ */