ReByteBuffer line;
int traceCount = 0;
while( (entry = traverser.rawNextFile(currentDepth))){
+ //@todo
+ ReByteBuffer dummy(entry->m_path); dummy.append(entry->node());
+ int passNo = entry->m_passNo;
+ const char* dummyStr = dummy.str();
if (currentDepth <= level && ! entry->m_path.equals(current->m_path)){
if (currentDepth <= topOfStack){
// close the entries of the stack above the new top level:
// set up a new stack entry:
if (currentDepth != topOfStack + 1)
assert(currentDepth == topOfStack + 1);
- //@todo
- if (strstr("dir2", entry->node()) != NULL || strstr("dir2", entry->m_path.str()))
- ReByteBuffer breaker;
topOfStack++;
if (dataStack[topOfStack] == NULL)
closedir(m_handle);\r
m_handle = opendir(m_path.str());\r
rc = m_handle != NULL && (m_data = readdir(m_handle)) != NULL;\r
+ m_status.st_ino = 0;\r
#elif defined __WIN32__\r
if (m_handle != INVALID_HANDLE_VALUE)\r
FindClose(m_handle);\r
bool ReDirStatus_t::findNext(){\r
#if defined __linux__\r
bool rc = m_handle != NULL && (m_data = readdir(m_handle)) != NULL;\r
+ m_status.st_ino = 0;\r
#elif defined __WIN32__\r
bool rc = m_handle != INVALID_HANDLE_VALUE && FindNextFileA(m_handle, &m_data);\r
#endif\r
*/\r
bool ReDirStatus_t::isDirectory() {\r
#ifdef __linux__\r
- return (m_data->d_type != DT_UNKNOWN && m_data->d_type == DT_DIR) || S_ISDIR(getStatus()->st_mode);\r
+ return m_data->d_type == DT_DIR\r
+ || (m_data->d_type == DT_UNKNOWN && S_ISDIR(getStatus()->st_mode));\r
#elif defined __WIN32__\r
return 0 != (m_data.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY);\r
#endif\r
bool ReDirStatus_t::isLink() {\r
bool rc;\r
#ifdef __linux__\r
- rc = (m_data->d_type != DT_UNKNOWN && m_data->d_type == DT_LNK) || S_ISLNK(getStatus()->st_mode);\r
+ rc = m_data->d_type == DT_LNK\r
+ || (m_data->d_type == DT_UNKNOWN && S_ISLNK(getStatus()->st_mode));\r
#elif defined __WIN32__\r
rc = 0 != (m_data.dwFileAttributes & FILE_ATTRIBUTE_REPARSE_POINT);\r
#endif\r
*/\r
bool ReDirStatus_t::isRegular() {\r
#ifdef __linux__\r
- return (m_data->d_type != DT_UNKNOWN && m_data->d_type == DT_REG) || S_ISREG(getStatus()->st_mode);\r
+ return m_data->d_type == DT_REG\r
+ || (m_data->d_type == DT_UNKNOWN && S_ISREG(getStatus()->st_mode));\r
#elif defined __WIN32__\r
return 0 == (m_data.dwFileAttributes & (FILE_ATTRIBUTE_REPARSE_POINT | FILE_ATTRIBUTE_DIRECTORY | FILE_ATTRIBUTE_DEVICE));\r
#endif\r