Don't allow search pattern in the filename yet. There's no way to solve it through ANSI C.

This commit is contained in:
Daniel Marjamäki 2007-07-26 06:17:25 +00:00
parent d3f30c0a6e
commit 639d5fe344
1 changed files with 1 additions and 26 deletions

View File

@ -11,8 +11,6 @@
#include "CheckHeaders.h"
#include "CheckOther.h"
#include <dir.h> // <- findfirst, ffblk
//---------------------------------------------------------------------------
bool Debug = false;
bool ShowAll = false;
@ -62,30 +60,7 @@ int main(int argc, char* argv[])
return 0;
}
struct ffblk f;
int done = findfirst(fname,&f,0);
while (!done)
{
char path[1000];
if (strchr(fname,'\\'))
{
strcpy(path, fname);
*(strrchr(path,'\\')+1) = 0;
}
else if (strchr(fname,'/'))
{
strcpy(path, fname);
*(strrchr(path,'/')+1) = 0;
}
else
{
path[0] = 0;
}
strcat(path, f.ff_name);
CppCheck(path);
done = findnext(&f);
}
CppCheck(fname);
return 0;
}