0:字符串中不包含字符c; >0 包含字符c.spa
int str_search(char *cstr,char c)debug
{字符串
int irs = 0;it
char *cp = cstr;bug
zlog_debug(fzs,"cp=%s",cp);while
zlog_debug(fzs,"c=%c",c);字符
while(*cp != 0)return
{search
if(*cp==c)arc
{
irs++;
}
cp++;
}
cp = NULL;
return irs;
}