Fix some issues with strcasecmp() conditional compilation and with memccpy() return value
This commit is contained in:
parent
2bacc40350
commit
0e3cd129ae
@ -81,16 +81,12 @@ FAR void *memccpy(FAR void *s1, FAR const void *s2, int c, size_t n)
|
||||
|
||||
/* Did we just copy the terminating byte c? */
|
||||
|
||||
if (*pout == (unsigned char)c)
|
||||
if (*pout++ == (unsigned char)c)
|
||||
{
|
||||
/* Yes return a pointer to the byte after the copy of c into s1 */
|
||||
|
||||
return (FAR void *)pout;
|
||||
}
|
||||
|
||||
/* No increment to the next destination location */
|
||||
|
||||
pout++;
|
||||
}
|
||||
|
||||
/* C was not found in the first n bytes of s2 */
|
||||
|
@ -46,7 +46,7 @@
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_ARCH_STRCMP
|
||||
#ifndef CONFIG_ARCH_STRCASECMP
|
||||
int strcasecmp(FAR const char *cs, FAR const char *ct)
|
||||
{
|
||||
int result;
|
||||
|
Loading…
Reference in New Issue
Block a user