summaryrefslogtreecommitdiffstats
path: root/cpukit/libmisc
diff options
context:
space:
mode:
authorAschref Ben Thabet <aschref.ben-thabet@embedded-brains.de>2020-08-18 17:31:21 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2020-08-20 07:44:33 +0200
commitcbfdcba5551a93ed6b3b6dfe965fd556cbb9837a (patch)
tree6cff7e16c970b1eda167068d68ba5f6fa7149a15 /cpukit/libmisc
parent05d5772c1c194bec54bef65136ddecd18cd30d25 (diff)
downloadrtems-cbfdcba5551a93ed6b3b6dfe965fd556cbb9837a.tar.bz2
Fix -Wchar-subscripts warnings
The argument to the ctype functions must be an int and the value of the character must be representable as an unsigned char or equal to the value of the macro EOF. If the argument has any other value, the behavior is undefined.
Diffstat (limited to 'cpukit/libmisc')
-rw-r--r--cpukit/libmisc/rtems-fdt/rtems-fdt-shell.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/cpukit/libmisc/rtems-fdt/rtems-fdt-shell.c b/cpukit/libmisc/rtems-fdt/rtems-fdt-shell.c
index b15103e53d..b0894c1d38 100644
--- a/cpukit/libmisc/rtems-fdt/rtems-fdt-shell.c
+++ b/cpukit/libmisc/rtems-fdt/rtems-fdt-shell.c
@@ -338,7 +338,7 @@ rtems_fdt_shell_set (int argc, char *argv[])
if (!rtems_fdt_get_value32 (argv[1], "reg", sizeof (uint32_t), &address))
return 1;
- if (isdigit (argv[mask_arg][0]))
+ if (isdigit ((unsigned char) argv[mask_arg][0]))
mask = strtoul (argv[mask_arg], 0, 0);
else
{
@@ -380,7 +380,7 @@ rtems_fdt_shell_cl (int argc, char *argv[])
if (!rtems_fdt_get_value32 (argv[1], "reg", sizeof (uint32_t), &address))
return 1;
- if (isdigit (argv[mask_arg][0]))
+ if (isdigit ((unsigned char) argv[mask_arg][0]))
mask = strtoul (argv[mask_arg], 0, 0);
else
{
@@ -426,7 +426,7 @@ rtems_fdt_shell_up (int argc, char *argv[])
if (!rtems_fdt_get_value32 (argv[1], "reg", sizeof (uint32_t), &address))
return 1;
- if (isdigit (argv[mask_arg][0]))
+ if (isdigit ((unsigned char) argv[mask_arg][0]))
mask = strtoul (argv[mask_arg], 0, 0);
else
{
@@ -473,7 +473,7 @@ rtems_fdt_shell_tst (int argc, char *argv[])
if (!rtems_fdt_get_value32 (argv[1], "reg", sizeof (uint32_t), &address))
return 1;
- if (isdigit (argv[mask_arg][0]))
+ if (isdigit ((unsigned char) argv[mask_arg][0]))
mask = strtoul (argv[mask_arg], 0, 0);
else
{