mirror of git://git.musl-libc.org/musl
strcmp: Remove unnecessary check for *r
If *l == *r && *l, then by transitivity, *r.
This commit is contained in:
parent
8ff810d779
commit
b300d5b7bd
|
@ -2,6 +2,6 @@
|
|||
|
||||
int strcmp(const char *l, const char *r)
|
||||
{
|
||||
for (; *l==*r && *l && *r; l++, r++);
|
||||
for (; *l==*r && *l; l++, r++);
|
||||
return *(unsigned char *)l - *(unsigned char *)r;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue