Is this
if( (FileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) &&
(wcscmp(FileData.cFileName, L".") != 0) &&
(wcscmp(FileData.cFileName, L"..") != 0) )
the same as this:
if( (FileData.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) &&
wcscmp(FileData.cFileName, L".") &&
wcscmp(FileData.cFileName, L"..") )
And also if you use strcmp
instead of wcscmp
? It should check equality (strict) of the name with ".." and "." (directory search).
Thanks!