[Fixed] Hexen and Heretic crash on startup [dev builds]

Bugs that have been investigated and resolved somehow.

Moderator: GZDoom Developers

Hexen and Heretic crash on startup [dev builds]

Postby Lippeth » Wed May 26, 2021 4:25 pm

Starting from gzdoom-x64-g4.7.0pre-6-gdfe6a09b8.7z, Hexen and Heretic attempt to start and then crash, no matter what settings are present.

The crash report I'm including is from gzdoom-x64-g4.7.0pre-8-g2ca2076a3.7z, while trying to load Heretic.
You do not have the required permissions to view the files attached to this post.
User avatar
Lippeth
Metalvangelist
 
Joined: 24 Apr 2013
Location: Lost Angeles
Discord: Lippeth#2552

Re: Hexen and Heretic crash on startup [dev builds]

Postby 0mnicydle » Wed May 26, 2021 6:07 pm

I'm seeing this too (divide by zero crash on startup). Also happens with Strife, but not any Doom iwads that I've noticed.

I narrowed this down to commit 5f02b92cd0843026a6bc20743915333041c96cd7
User avatar
0mnicydle
 
Joined: 27 Jun 2013

Re: Hexen and Heretic crash on startup [dev builds]

Postby Lord Misfit » Wed May 26, 2021 6:25 pm

So while I noticed the "divide by zero" issue you guys have with Heretic and Hexen on 4.7pre[6/8], I'm additionally having another crash of sorts with my own mod Aetherius when I go to a level, or load a save game (this also happens when playing in Doom mode, as well as at least Heretic). Also weirdly enough, if I load Heretic/Hexen with the mod, I can get past the startup, but loading a save or going into a map will crash it, and it's also started as of the same version. I wonder if it has anything to do with the fact the mod adds and/or alters some fonts, which is the crux of that specific SVN where it started doing this.

So for now I have to stay on 4.7pre4 until I know what to do or something gets fixed.
You do not have the required permissions to view the files attached to this post.
User avatar
Lord Misfit
Servant of Aetherius? Servant of Siel?
 
Joined: 27 Dec 2006
Location: Canton, OH
Discord: Lord Misfit#9594

Re: Hexen and Heretic crash on startup [dev builds]

Postby lemming » Wed May 26, 2021 7:34 pm

It seems to be a consequence of the font/palette changes that were recently introduced.

Just to possibly save the devs a little time:

This is the stack:
> gzdoom.exe!V_ApplyLuminosityTranslation(int translation, unsigned char * pixel, int size) Line 680 C++
gzdoom.exe!FSpecialFont::LoadTranslations() Line 176 C++
gzdoom.exe!V_LoadTranslations() Line 998 C++
gzdoom.exe!D_DoomMain_Internal() Line 3413 C++
gzdoom.exe!GameMain() Line 3681 C++
gzdoom.exe!DoMain(HINSTANCE__ * hInstance) Line 971 C++
gzdoom.exe!wWinMain(HINSTANCE__ * hInstance, HINSTANCE__ * nothing, wchar_t * cmdline, int nCmdShow) Line 1260 C++
[Inline Frame] gzdoom.exe!invoke_main() Line 118 C++
gzdoom.exe!__scrt_common_main_seh() Line 288 C++


And the offending block of code in common\fonts\v_font.cpp, around line 680:
else if (gray > lum_max)
{
newcol.r = clamp(newcol.r * gray / lum_max, 0, 255);
newcol.g = clamp(newcol.g * gray / lum_max, 0, 255);
newcol.b = clamp(newcol.b * gray / lum_max, 0, 255);
}


In Heretic, this fails because lum_min and lum_max are zero.
lemming
 
Joined: 10 Nov 2018

Re: Hexen and Heretic crash on startup [dev builds]

Postby Graf Zahl » Thu May 27, 2021 6:05 am

It crashed on an empty font without any characters, courtesy of FONTDEFS.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany

Re: Hexen and Heretic crash on startup [dev builds]

Postby Lord Misfit » Thu May 27, 2021 12:19 pm

My apologies from having to post here, but... I went and grabbed 4.7pre-9 off github directly, and while it does seem to fix the initial issue the others are having, my own crash issue when loading a save-game or a new map is still happening, and as I mentioned, 4.7pre-6 was also when it was introduced [and thus I assumed maybe my issue was also a font-related one]. I've posted the new crash log. Lemme know if it's saying my fonts are having a problem or not, if you could. I took a quick look over my FONTDEFs, and nothing seemed off to me when I glanced over it, but maybe I'm not catching something? o.o
You do not have the required permissions to view the files attached to this post.
User avatar
Lord Misfit
Servant of Aetherius? Servant of Siel?
 
Joined: 27 Dec 2006
Location: Canton, OH
Discord: Lord Misfit#9594

Re: Hexen and Heretic crash on startup [dev builds]

Postby Graf Zahl » Thu May 27, 2021 12:54 pm

Please do not post your bug reports in closed threads. Also, always post the material you used to reproduce it.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany


Return to Closed Bugs

Who is online

Users browsing this forum: No registered users and 1 guest