mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-10 23:01:50 +00:00
- marked a few Printf calls in critical error paths as PRINT_NONOTIFY.
This commit is contained in:
parent
07f08de474
commit
ef887403cf
5 changed files with 7 additions and 8 deletions
|
@ -683,7 +683,7 @@ void FSerializer::ReadObjects(bool hubtravel)
|
|||
{
|
||||
r->mObjects.Clamp(size); // close all inner objects.
|
||||
// In case something in here throws an error, let's continue and deal with it later.
|
||||
Printf(TEXTCOLOR_RED "'%s'\n while restoring %s\n", err.GetMessage(), obj ? obj->GetClass()->TypeName.GetChars() : "invalid object");
|
||||
Printf(PRINT_NONOTIFY, TEXTCOLOR_RED "'%s'\n while restoring %s\n", err.GetMessage(), obj ? obj->GetClass()->TypeName.GetChars() : "invalid object");
|
||||
mErrors++;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -925,7 +925,7 @@ void M_Init (void)
|
|||
catch (CVMAbortException &err)
|
||||
{
|
||||
err.MaybePrintMessage();
|
||||
Printf("%s", err.stacktrace.GetChars());
|
||||
Printf(PRINT_NONOTIFY, "%s", err.stacktrace.GetChars());
|
||||
I_FatalError("Failed to initialize menus");
|
||||
}
|
||||
M_CreateMenus();
|
||||
|
|
|
@ -682,8 +682,7 @@ void CVMAbortException::MaybePrintMessage()
|
|||
auto m = GetMessage();
|
||||
if (m != nullptr)
|
||||
{
|
||||
Printf(TEXTCOLOR_RED);
|
||||
Printf("%s\n", m);
|
||||
Printf(PRINT_NONOTIFY, TEXTCOLOR_RED "%s\n", m);
|
||||
SetMessage("");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1231,14 +1231,14 @@ void D_DoomLoop ()
|
|||
{
|
||||
if (error.GetMessage ())
|
||||
{
|
||||
Printf (PRINT_BOLD, "\n%s\n", error.GetMessage());
|
||||
Printf (PRINT_NONOTIFY | PRINT_BOLD, "\n%s\n", error.GetMessage());
|
||||
}
|
||||
D_ErrorCleanup ();
|
||||
}
|
||||
catch (CVMAbortException &error)
|
||||
{
|
||||
error.MaybePrintMessage();
|
||||
Printf("%s", error.stacktrace.GetChars());
|
||||
Printf(PRINT_NONOTIFY, "%s", error.stacktrace.GetChars());
|
||||
D_ErrorCleanup();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -538,7 +538,7 @@ bool FThinkerList::DoDestroyThinkers()
|
|||
{
|
||||
Printf("VM exception in DestroyThinkers:\n");
|
||||
exception.MaybePrintMessage();
|
||||
Printf("%s", exception.stacktrace.GetChars());
|
||||
Printf(PRINT_NONOTIFY, "%s", exception.stacktrace.GetChars());
|
||||
// forcibly delete this. Cleanup may be incomplete, though.
|
||||
node->ObjectFlags |= OF_YesReallyDelete;
|
||||
delete node;
|
||||
|
@ -546,7 +546,7 @@ bool FThinkerList::DoDestroyThinkers()
|
|||
}
|
||||
catch (CRecoverableError &exception)
|
||||
{
|
||||
Printf("Error in DestroyThinkers: %s\n", exception.GetMessage());
|
||||
Printf(PRINT_NONOTIFY, "Error in DestroyThinkers: %s\n", exception.GetMessage());
|
||||
// forcibly delete this. Cleanup may be incomplete, though.
|
||||
node->ObjectFlags |= OF_YesReallyDelete;
|
||||
delete node;
|
||||
|
|
Loading…
Reference in a new issue