Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8523 in orxonox.OLD for trunk/src/lib/util


Ignore:
Timestamp:
Jun 16, 2006, 11:16:38 AM (19 years ago)
Author:
bensch
Message:

trunk: compiles on Windows: DANGER: THE LINUX PORT MAY BE COMPROMISED

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/util/filesys/directory.cc

    r8332 r8523  
    9999    return false;
    100100  }
     101
     102  dirent* entry;
     103  while ((entry = readdir(handle)) != NULL)
     104    this->_fileNames.push_back(entry->d_name);
     105  closedir(handle);
     106
    101107#else
    102108  HANDLE handle;
     
    124130    this->_fileNames.push_back(entry.cFileName);
    125131  }
    126 #endif
    127 
    128   // BUILDING the list of contained Files. (only the names)
    129 #if not defined(__WIN32__)
    130   dirent* entry;
    131   while ((entry = readdir(handle)) != NULL)
    132     this->_fileNames.push_back(entry->d_name);
    133   closedir(handle);
    134 #else
    135   WIN32_FIND_DATA entry;
    136   while ((int ok = FindNextFile(handle, &entry)) != 0)
     132  int ok;
     133  while ((ok = FindNextFile(handle, &entry)) != 0)
    137134    this->_fileNames.push_back(entry.cFileName);
    138135  FindClose(handle);
    139 #endif
     136#endif /* __WIN_32__ */
     137
    140138  this->_opened = true;
    141139  return true;
Note: See TracChangeset for help on using the changeset viewer.