Re: Host crashed
From: | streu |
---|---|
Thread: | Host crashed |
Forum: | FLAK 1 |
In reply to: | Re: Host crashed |
Date: | Sun, 2022-04-10 09:00 GMT |
ok, fixed it. When ExploreMap was trying to understand your UTIL.DAT files (so you see the location of all planets you Sensor Sweep), it tried to read past the end due to a broken end-of-file check.
This has always been wrong, but got triggered by FLAK now writing Explosion markers.
I fixed it; next turn should run normally again.
--Stefan
--- explmap.c 3 Jun 2012 18:21:32 -0000 1.1 +++ explmap.c 10 Apr 2022 08:47:12 -0000 @@ -255,8 +255,7 @@ sprintf(utilFileName, "util%d.dat", i); F = OpenInputFile(utilFileName, GAME_DIR_ONLY | NO_MISSING_ERROR); if (F != NULL) { - while (!feof(F)) { - DOSRead16((Uns16 *)&header, 2, F); + while (DOSRead16((Uns16 *)&header, 2, F)) { if (header.type == 6 /* Sensor Sweep */ || header.type == 23 /* Bioscan */ || (gConfig->DarkSenseLocates && header.type == 3))