/* This function will compare two strings while ignoring differences in case.  */
rt_int32_t rt_strcasecmp(const char *a, const char *b)
/* This function will compare two strings while ignoring differences in case.  */
rt_int32_t rt_strcasecmp(const char *a, const char *b)
{
    int ca = 0, cb = 0;
    do
    {
        ca = *a++ & 0xff;
        cb = *b++ & 0xff;
        if (ca >= 'A' && ca <= 'Z')
            ca += 'a' - 'A';
        if (cb >= 'A' && cb <= 'Z')
            cb += 'a' - 'A';
    }
    while (ca == cb && ca != '\0');
    return ca - cb;
}