| 356 | int num_orphan_ignore = sizeof(orphan_ignore) / sizeof(char *); |
| 357 | |
| 358 | bool IsFileUsed(char *filename) { |
| 359 | bool found = false; |
| 360 | |
| 361 | for (int i = 0; i < num_orphan_ignore; i++) { |
| 362 | if (!stricmp(filename, orphan_ignore[i])) { |
| 363 | found = true; |
| 364 | goto done; |
| 365 | } |
| 366 | } |
| 367 | |
| 368 | if (!found) |
| 369 | found = IsFileInGameFile(filename); |
| 370 | if (!found) |
| 371 | found = IsFileInWeaponPage(filename); |
| 372 | if (!found) |
| 373 | found = IsFileInSoundPage(filename); |
| 374 | if (!found) |
| 375 | found = IsFileInShipPage(filename); |
| 376 | if (!found) |
| 377 | found = IsFileInDoorPage(filename); |
| 378 | if (!found) |
| 379 | found = IsFileInTexturePage(filename); |
| 380 | if (!found) |
| 381 | found = IsFileInGenericPage(filename); |
| 382 | |
| 383 | done: |
| 384 | Descent->defer(); |
| 385 | |
| 386 | return found; |
| 387 | } |
| 388 | |
| 389 | int filelen(char *filename, char *dir) { |
| 390 | char path[_MAX_PATH]; |
no test coverage detected