提交 b300d5b7 编写于 作者: M Michael Forney 提交者: Rich Felker

strcmp: Remove unnecessary check for *r

If *l == *r && *l, then by transitivity, *r.
上级 8ff810d7
......@@ -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;
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册