mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 00:14:22 +08:00
libc: Change the return type of strerror from "const char *" to "char *"
to follow up the spec here: https://pubs.opengroup.org/onlinepubs/9699919799/functions/strerror.html Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
committed by
Petro Karashchenko
parent
fa42ebace4
commit
6b8274fbd8
@@ -38,8 +38,8 @@
|
||||
|
||||
struct errno_strmap_s
|
||||
{
|
||||
uint8_t errnum;
|
||||
const char *str;
|
||||
uint8_t errnum;
|
||||
FAR char *str;
|
||||
};
|
||||
|
||||
/****************************************************************************
|
||||
@@ -341,7 +341,7 @@ static const struct errno_strmap_s g_errnomap[] =
|
||||
* Name: strerror
|
||||
****************************************************************************/
|
||||
|
||||
FAR const char *strerror(int errnum)
|
||||
FAR char *strerror(int errnum)
|
||||
{
|
||||
#ifdef CONFIG_LIBC_STRERROR
|
||||
int ndxlow = 0;
|
||||
|
||||
Reference in New Issue
Block a user