The International Simutrans Forum

Development => Patches & Projects => Incorporated Patches and Solved Bug Reports => Topic started by: Colin on November 14, 2011, 04:14:42 AM

Title: Fatal Error
Post by: Colin on November 14, 2011, 04:14:42 AM
Hi Guy's. One of my save games has come up with the following error.

FATAL ERROR: Loadsave_t::rdwr_str()
string longer (2248) than
allowed size (128) PRESS ANY KEY.

Now I know this SVE worked but since I've installed WIN 7 Ultimate 64bit it doesn't any more. Yet SVE's from saves a month previously do.

I don't know if you can help, if not it means I've lost a months work.
Title: Re: Fatal Error
Post by: Dwachs on November 14, 2011, 08:20:05 AM
could you upload the save?
Title: Re: Fatal Error
Post by: Colin on November 14, 2011, 09:44:51 AM
Quote from: Dwachs on November 14, 2011, 08:20:05 AM
could you upload the save?

Yes, but I've forgotten where to upload it to. I can't do it here because its 2743KB. I could probably email it to you?
Title: Re: Fatal Error
Post by: Dwachs on November 15, 2011, 09:02:16 AM
The savegame is corrupted, it should be much larger. That said, it is not completely saved.
Title: Re: Fatal Error
Post by: Colin on November 16, 2011, 12:39:12 AM
Quote from: Dwachs on November 15, 2011, 09:02:16 AM
The savegame is corrupted, it should be much larger. That said, it is not completely saved.
That's strange because the 2 SVE's I have from October are 2464KB and 2496KB. They are very similar, just missing the work that I'd done in the next 3 weeks or so, and they work. I would have thought that the extra 47KB just applied to that extra work?

I knew it was corrupted otherwise it would have worked, I was wondering if using an HEX Editor or a Compiler would find the corruption? It would appear to be at the start of the file as there a lot of things there that are not in the others SVE's. As I'm not a programmer I'm lost beyond that. What language is Simutrans written in maybe my son in law could look at it?
Title: Re: Fatal Error
Post by: Dwachs on November 16, 2011, 07:15:50 AM
That sounds strange. The fatal error comes from the fact that simutrans wants to read the savegame beyond its end, there seems to be some data lost. Imho These lost data cannot be recovered by hex editor or hacking the source code. (Simutrans is written in C++)
Title: Re: Fatal Error
Post by: Colin on November 16, 2011, 08:15:18 AM
Quote from: Dwachs on November 16, 2011, 07:15:50 AM
That sounds strange. The fatal error comes from the fact that simutrans wants to read the savegame beyond its end, there seems to be some data lost. Imho These lost data cannot be recovered by hex editor or hacking the source code. (Simutrans is written in C++)

What does it actually mean then when it say's  the, "string LONGER (2248) than the allowed size (128)" if you are saying that it should be  even longer?
Title: Re: Fatal Error
Post by: VS on November 16, 2011, 08:55:11 AM
Dwachs is trying to say: The file should be longer, it is clearly missing its end.

Simutrans is trying to say: Here I'm reading from the file some string and suddenly I can't see its end! WTF?

What actually happens is: the string is cut in the middle by unexpected end of the file and so appears to not have an end.

(OK, I may be simplifying somewhat, but that is a good enough explanation, I hope :) )
Title: Re: Fatal Error
Post by: Colin on November 17, 2011, 12:25:16 AM
Thanks VS, I understand now and thanks Dwack for your help. It looks like i'll have to do it all over again.