Ignore:
Timestamp:
Mar 12, 2010, 4:26:16 PM (11 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 5, master
Children:
88353c4
Parents:
3c02c9dd
Message:

2010-03-12 Joel Sherrill <joel.sherrill@…>

  • ftpd/ftpd.c, httpd/asp.c, httpd/ejparse.c, httpd/emfdb.c, httpd/misc.c, httpd/um.c, httpd/webs.c, httpd/websuemf.c, libfs/src/dosfs/msdos_dir.c, libfs/src/dosfs/msdos_format.c, libfs/src/dosfs/msdos_misc.c, libfs/src/nfsclient/src/nfs.c, libmisc/capture/capture-cli.c, libmisc/monitor/mon-network.c, libmisc/shell/hexdump-odsyntax.c, libmisc/shell/main_ifconfig.c, libmisc/shell/shell.c, libmisc/shell/shell_makeargs.c, libmisc/uuid/parse.c, libnetworking/libc/gethostbydns.c, libnetworking/libc/gethostbyht.c, libnetworking/libc/gethostnamadr.c, libnetworking/libc/getnetnamadr.c, libnetworking/libc/inet_addr.c, libnetworking/libc/inet_network.c, libnetworking/libc/res_debug.c, libnetworking/libc/res_init.c, libnetworking/libc/res_query.c, libnetworking/rtems/rtems_mii_ioctl.c, score/src/objectgetnameasstring.c: Readdress use of ctype methods per recommendation from D.J. Delorie on the newlib mailing list. We should pass an unsigned char into these methods.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/libmisc/shell/hexdump-odsyntax.c

    r3c02c9dd rbab5c5fa  
    220220
    221221        if (*p != '+' && (argc < 2 ||
    222             (!isdigit((int)p[0]) && (p[0] != 'x' || !isxdigit((int)p[1])))))
     222            (!isdigit((unsigned char)p[0]) && (p[0] != 'x' || !isxdigit((unsigned char)p[1])))))
    223223                return;
    224224
     
    230230        if (p[0] == '+')
    231231                ++p;
    232         if (p[0] == 'x' && isxdigit((int)p[1])) {
     232        if (p[0] == 'x' && isxdigit((unsigned char)p[1])) {
    233233                ++p;
    234234                base = 16;
     
    240240        /* skip over the number */
    241241        if (base == 16)
    242                 for (num = p; isxdigit((int)*p); ++p);
     242                for (num = p; isxdigit((unsigned char)*p); ++p);
    243243        else
    244                 for (num = p; isdigit((int)*p); ++p);
     244                for (num = p; isdigit((unsigned char)*p); ++p);
    245245
    246246        /* check for no number */
Note: See TracChangeset for help on using the changeset viewer.