Skip to content

Filesystem cleanup; avoid throwing non-serious exceptions#1977

Open
slipher wants to merge 3 commits into
DaemonEngine:masterfrom
slipher:fs-except
Open

Filesystem cleanup; avoid throwing non-serious exceptions#1977
slipher wants to merge 3 commits into
DaemonEngine:masterfrom
slipher:fs-except

Conversation

@slipher
Copy link
Copy Markdown
Member

@slipher slipher commented Jun 5, 2026

A bit of filesystem cleanup. Most importantly, this avoids the throwing of exceptions for things that aren't serious errors. So now you can configure your debugger to break on all exceptions and get only relevant stuff.

slipher added 3 commits June 5, 2026 04:02
If we couldn't access pakpath files, that should be a fatal error
as those are crucial for the engine/game to function. But a file
exception can't really happen there anyway since it's just iterating a
std::map.
Remove FS_GetFileList, FS_FreeFile, FS_FreeFileList.
This function typically threw exceptions several time during startup,
due to checking nonexistent base directories in the gamepath. Use
the non-throwing variant of FS::HomePath::ListFiles so that
`throw` is not used.

This makes it possible to configure a debugger to break on all exceptions
and not get tripped up by cases that aren't truly exceptional.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant