This revision was automatically updated to reflect the committed changes.
Closed by commit rL272827: Add an Android version check for GNU strerror_r. 
(authored by danalbert).

Changed prior to commit:
  http://reviews.llvm.org/D21402?vs=60887&id=60893#toc

Repository:
  rL LLVM

http://reviews.llvm.org/D21402

Files:
  libcxx/trunk/src/system_error.cpp

Index: libcxx/trunk/src/system_error.cpp
===================================================================
--- libcxx/trunk/src/system_error.cpp
+++ libcxx/trunk/src/system_error.cpp
@@ -21,6 +21,10 @@
 #include "string"
 #include "string.h"
 
+#if defined(__ANDROID__)
+#include <android/api-level.h>
+#endif
+
 _LIBCPP_BEGIN_NAMESPACE_STD
 
 // class error_category
@@ -58,7 +62,8 @@
 
 string do_strerror_r(int ev);
 
-#if defined(__linux__) && !defined(_LIBCPP_HAS_MUSL_LIBC)
+#if defined(__linux__) && !defined(_LIBCPP_HAS_MUSL_LIBC)                      
\
+    && (!defined(__ANDROID__) || __ANDROID_API__ >= 23)
 // GNU Extended version
 string do_strerror_r(int ev) {
     char buffer[strerror_buff_size];


Index: libcxx/trunk/src/system_error.cpp
===================================================================
--- libcxx/trunk/src/system_error.cpp
+++ libcxx/trunk/src/system_error.cpp
@@ -21,6 +21,10 @@
 #include "string"
 #include "string.h"
 
+#if defined(__ANDROID__)
+#include <android/api-level.h>
+#endif
+
 _LIBCPP_BEGIN_NAMESPACE_STD
 
 // class error_category
@@ -58,7 +62,8 @@
 
 string do_strerror_r(int ev);
 
-#if defined(__linux__) && !defined(_LIBCPP_HAS_MUSL_LIBC)
+#if defined(__linux__) && !defined(_LIBCPP_HAS_MUSL_LIBC)                      \
+    && (!defined(__ANDROID__) || __ANDROID_API__ >= 23)
 // GNU Extended version
 string do_strerror_r(int ev) {
     char buffer[strerror_buff_size];
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to