OSDN Git Service

Add strtof_l and strtod_l.
authorDan Albert <danalbert@google.com>
Wed, 21 Sep 2016 08:42:19 +0000 (01:42 -0700)
committerDan Albert <danalbert@google.com>
Thu, 22 Sep 2016 07:44:37 +0000 (00:44 -0700)
libc++ needs these now. Add shims to match the others.

Test: make checkbuild tests
Bug: http://b/31639993
Change-Id: Ifec6c32099145d8d3d1a5639a4809e5e9f553c33

libc/bionic/locale.cpp
libc/include/stdlib.h
libc/libc.arm.map
libc/libc.arm64.map
libc/libc.map.txt
libc/libc.mips.map
libc/libc.mips64.map
libc/libc.x86.map
libc/libc.x86_64.map

index 2a4ce68..e51b38c 100644 (file)
@@ -196,6 +196,18 @@ int strncasecmp_l(const char* s1, const char* s2, size_t n, locale_t) {
   return strncasecmp(s1, s2, n);
 }
 
+double strtod_l(const char* s, char** end_ptr, locale_t) {
+  return strtod(s, end_ptr);
+}
+
+float strtof_l(const char* s, char** end_ptr, locale_t) {
+  return strtof(s, end_ptr);
+}
+
+long strtol_l(const char* s, char** end_ptr, int base, locale_t) {
+  return strtol(s, end_ptr, base);
+}
+
 long double strtold_l(const char* s, char** end_ptr, locale_t) {
   return strtold(s, end_ptr);
 }
@@ -204,6 +216,10 @@ long long strtoll_l(const char* s, char** end_ptr, int base, locale_t) {
   return strtoll(s, end_ptr, base);
 }
 
+unsigned long strtoul_l(const char* s, char** end_ptr, int base, locale_t) {
+  return strtoul(s, end_ptr, base);
+}
+
 unsigned long long strtoull_l(const char* s, char** end_ptr, int base, locale_t) {
   return strtoull(s, end_ptr, base);
 }
index 6b0ec12..f7f4014 100644 (file)
@@ -77,8 +77,12 @@ int posix_memalign(void** memptr, size_t alignment, size_t size) __INTRODUCED_IN
 double strtod(const char*, char**);
 long double strtold(const char*, char**) __INTRODUCED_IN(21);
 
+double strtod_l(const char*, char**, locale_t) __INTRODUCED_IN_FUTURE;
+float strtof_l(const char*, char**, locale_t) __INTRODUCED_IN_FUTURE;
+long strtol_l(const char*, char**, int, locale_t) __INTRODUCED_IN_FUTURE;
 long double strtold_l(const char*, char**, locale_t) __INTRODUCED_IN(21);
 long long strtoll_l(const char*, char**, int, locale_t) __INTRODUCED_IN(21);
+unsigned long strtoul_l(const char*, char**, int, locale_t) __INTRODUCED_IN_FUTURE;
 unsigned long long strtoull_l(const char*, char**, int, locale_t) __INTRODUCED_IN(21);
 
 int atoi(const char*) __purefunc;
index c4243f4..eb75e8f 100644 (file)
@@ -1306,6 +1306,10 @@ LIBC_O {
     sigpause; # future
     sigrelse; # future
     sigset; # future
+    strtod_l; # future
+    strtof_l; # future
+    strtol_l; # future
+    strtoul_l; # future
     sync_file_range; # future
     towctrans; # future
     towctrans_l; # future
index 2393d22..28755d4 100644 (file)
@@ -1228,6 +1228,10 @@ LIBC_O {
     sigpause; # future
     sigrelse; # future
     sigset; # future
+    strtod_l; # future
+    strtof_l; # future
+    strtol_l; # future
+    strtoul_l; # future
     sync_file_range; # future
     towctrans; # future
     towctrans_l; # future
index 19fdb4b..1fba8ee 100644 (file)
@@ -1331,6 +1331,10 @@ LIBC_O {
     sigpause; # future
     sigrelse; # future
     sigset; # future
+    strtod_l; # future
+    strtof_l; # future
+    strtol_l; # future
+    strtoul_l; # future
     sync_file_range; # future
     towctrans; # future
     towctrans_l; # future
index 1461dc5..f61f615 100644 (file)
@@ -1290,6 +1290,10 @@ LIBC_O {
     sigpause; # future
     sigrelse; # future
     sigset; # future
+    strtod_l; # future
+    strtof_l; # future
+    strtol_l; # future
+    strtoul_l; # future
     sync_file_range; # future
     towctrans; # future
     towctrans_l; # future
index 2393d22..28755d4 100644 (file)
@@ -1228,6 +1228,10 @@ LIBC_O {
     sigpause; # future
     sigrelse; # future
     sigset; # future
+    strtod_l; # future
+    strtof_l; # future
+    strtol_l; # future
+    strtoul_l; # future
     sync_file_range; # future
     towctrans; # future
     towctrans_l; # future
index 57b81a8..a166361 100644 (file)
@@ -1288,6 +1288,10 @@ LIBC_O {
     sigpause; # future
     sigrelse; # future
     sigset; # future
+    strtod_l; # future
+    strtof_l; # future
+    strtol_l; # future
+    strtoul_l; # future
     sync_file_range; # future
     towctrans; # future
     towctrans_l; # future
index 2393d22..28755d4 100644 (file)
@@ -1228,6 +1228,10 @@ LIBC_O {
     sigpause; # future
     sigrelse; # future
     sigset; # future
+    strtod_l; # future
+    strtof_l; # future
+    strtol_l; # future
+    strtoul_l; # future
     sync_file_range; # future
     towctrans; # future
     towctrans_l; # future