1 Star 0 Fork 0

houmingzhang/CovAnalysisTool

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
SharedFuncs.cpp 973 Bytes
一键复制 编辑 原始数据 按行查看 历史
Administrator 提交于 2021-10-05 19:06 +08:00 . 协相关分析工具
#include "SharedFuncs.h"
#include "GlobalHeader.h"
int mystricmp(const char *str1, const char *str2)
{
assert(str1 != NULL && str2 != NULL);
int ncount = strlen(str2);
while (ncount > 0 && *str1 != '\0')
{
if ((*str2 >= 'a' && *str2 <= 'z')
|| (*str2 >= 'A' && *str2 <= 'Z'))
{
if (((*str2 - *str1) == ('a' - 'A'))
|| ((*str1 - *str2) == ('a' - 'A')))
{
str1++;
str2++;
ncount--;
continue;
}
}
if (*str1 - *str2 > 0)
{
return 1;
}
if (*str1 - *str2 < 0)
{
return -1;
}
str1++;
str2++;
ncount--;
}
if (ncount != 0)
{
return 1;
}
return 0;
}
void PrintMemory(const char * tips,const char * ptr,int start,int end)
{
printf("tips:%s,打印大小:%d.\n",tips,end-start);
int i=0;
for(i=start;i<end;i++)
{
printf("0x%x ",*(ptr+i));
if((i+1)%16==0)
printf("\n");
else if((i+1)%8==0)
printf(" ");
}
printf("==================\n");
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/dtrylzhm/cov-analysis-tool.git
git@gitee.com:dtrylzhm/cov-analysis-tool.git
dtrylzhm
cov-analysis-tool
CovAnalysisTool
master

搜索帮助