int strcmp(const char *src, const char *dst)
{
int ret = 0;
if (src == dst)
{
return 0;
}
assert(src!=NULL);
if (dst == NULL)
{
return -1;
}
while(!(ret=*(unsigned char*)src-*(unsigned char*)dst)&&*dst)
{
src++,dst++;
}
if (ret<0)
{
return -1;
}
else if (ret>0)
{
return 1;
}
return ret;
}