You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix Windows crash saving tool definitions to a read-only install dir (#5)
On Windows GetDataDirectory() returned ".", so tool definitions and CSV
recordings were written relative to the working directory. For an app
installed under C:\Program Files\ that directory is read-only, so
create_directories() failed; SaveToolDefinition() used the throwing
overload, so the filesystem_error propagated to main() and terminated the
app when clicking "Add Tool Definition" (reported with no device attached,
but the save path is device-independent).
- GetDataDirectory(): use %LOCALAPPDATA%\IR Tracking App on Windows, a
writable per-user location, mirroring the macOS Application Support
handling. _wdupenv_s avoids the MSVC getenv deprecation warning under /W4
and preserves non-ASCII user names.
- SaveToolDefinition(): use the non-throwing create_directories overload;
log and skip persistence on failure instead of crashing. The tool stays
active for the session even if it can't be written to disk.
0 commit comments