Don't pass the AppHooks as pointer

It's not permitted to pass a nullptr to the `app_hooks_update`. So a
reference should be used.

CppCheck says one shouldn't take pointer to a temporary.
This commit is contained in:
phosit
2025-11-20 19:11:30 +01:00
parent b17c2fb80f
commit 977bf5c0d1
3 changed files with 5 additions and 8 deletions
+2 -3
View File
@@ -208,12 +208,11 @@ void InitVfs(const CmdLineArgs& args)
psSetLogDir(logs);
// desired location for crashlog is now known. update AppHooks ASAP
// (particularly before the following error-prone operations):
AppHooks hooks{
app_hooks_update({
.get_log_dir = psLogDir,
.bundle_logs = psBundleLogs,
.display_error = psDisplayError
};
app_hooks_update(&hooks);
});
g_VFS = CreateVfs();