Fix incorrect API level for wcstombs and mbstowcs.

Mbstowcs and wcstombs cannot get correct return value when called in the environment below api 21, and need to raise the API level to solve the problem.

Test: None
fix bug 1108 https://github.com/android/ndk/issues/1108

Change-Id: Iabcf1bff0be087288646687732ef68870630b48a
This commit is contained in:
ZijunZhao 2021-10-26 00:00:07 +00:00
parent dc4b3789e6
commit 57474c89fe
2 changed files with 4 additions and 4 deletions

View File

@ -161,11 +161,11 @@ const char* getprogname(void) __INTRODUCED_IN(21);
void setprogname(const char* __name) __INTRODUCED_IN(21);
int mblen(const char* __s, size_t __n) __INTRODUCED_IN_NO_GUARD_FOR_NDK(26);
size_t mbstowcs(wchar_t* __dst, const char* __src, size_t __n);
size_t mbstowcs(wchar_t* __dst, const char* __src, size_t __n) __INTRODUCED_IN(21) __VERSIONER_NO_GUARD;
int mbtowc(wchar_t* __wc_ptr, const char* __s, size_t __n) __INTRODUCED_IN_NO_GUARD_FOR_NDK(21);
int wctomb(char* __dst, wchar_t __wc) __INTRODUCED_IN_NO_GUARD_FOR_NDK(21);
size_t wcstombs(char* __dst, const wchar_t* __src, size_t __n);
size_t wcstombs(char* __dst, const wchar_t* __src, size_t __n) __INTRODUCED_IN(21) __VERSIONER_NO_GUARD;
#if __ANDROID_API__ >= 21
size_t __ctype_get_mb_cur_max(void) __INTRODUCED_IN(21);

View File

@ -631,7 +631,7 @@ LIBC {
mbsinit;
mbsnrtowcs; # introduced=21
mbsrtowcs;
mbstowcs;
mbstowcs; # introduced=21
mbtowc; # introduced=21
memalign;
memccpy;
@ -1194,7 +1194,7 @@ LIBC {
wcstold_l; # introduced=21
wcstoll; # introduced=21
wcstoll_l; # introduced=21
wcstombs;
wcstombs; # introduced=21
wcstoul;
wcstoull; # introduced=21
wcstoull_l; # introduced=21