| 465 | } |
| 466 | |
| 467 | void listdirsrecursive(const char *dir, vector<char *> &subdirs, int level) |
| 468 | { |
| 469 | if(level > 8) return; // 8 levels is insane enough... |
| 470 | vector<char *> dirs; |
| 471 | listsubdirs(dir, dirs, stringsort); |
| 472 | loopv(dirs) |
| 473 | { |
| 474 | if(dirs[i][0] != '.') // ignore "." and ".." (and also other directories starting with '.', like it is unix-convention - and doesn't hurt on windows) |
| 475 | { |
| 476 | defformatstring(name)("%s/%s", dir, dirs[i]); |
| 477 | subdirs.add(newstring(name)); |
| 478 | listdirsrecursive(name, subdirs, level + 1); |
| 479 | } |
| 480 | delstring(dirs[i]); |
| 481 | } |
| 482 | } |
| 483 | #endif |
| 484 | |
| 485 | bool delfile(const char *path) |
no test coverage detected