diff options
Diffstat (limited to 'include/wchar.h')
| -rw-r--r-- | include/wchar.h | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/include/wchar.h b/include/wchar.h index 7a2a192..e7e3db6 100644 --- a/include/wchar.h +++ b/include/wchar.h | |||
| @@ -224,21 +224,6 @@ _FORTIFY_FN(wcsrtombs) size_t wcsrtombs(char * _FORTIFY_POS0 __d, | |||
| 224 | return __r; | 224 | return __r; |
| 225 | } | 225 | } |
| 226 | 226 | ||
| 227 | #ifdef MB_CUR_MAX | ||
| 228 | #undef wctomb | ||
| 229 | #if __has_builtin(__builtin_wctomb) | ||
| 230 | __diagnose_as_builtin(__builtin_wctomb, 1, 2) | ||
| 231 | #endif | ||
| 232 | _FORTIFY_FN(wctomb) int wctomb(char * _FORTIFY_POS0 __s, wchar_t __w) | ||
| 233 | { | ||
| 234 | __fh_size_t __b = __bos(__s, 0); | ||
| 235 | |||
| 236 | if (__s && 16 > __b && MB_CUR_MAX > __b) | ||
| 237 | __builtin_trap(); | ||
| 238 | return __orig_wctomb(__s, __w); | ||
| 239 | } | ||
| 240 | #endif // MB_CUR_MAX | ||
| 241 | |||
| 242 | #if __has_builtin(__builtin_wmemcpy) | 227 | #if __has_builtin(__builtin_wmemcpy) |
| 243 | __diagnose_as_builtin(__builtin_wmemcpy, 1, 2, 3) | 228 | __diagnose_as_builtin(__builtin_wmemcpy, 1, 2, 3) |
| 244 | #endif | 229 | #endif |
