Assertion in GetRawSprite in r11440 and later
Posted: 28 Nov 2007 20:53
A few days ago I downloaded a nightly version of OpenTTD (I hadn't done this in a couple of weeks) and I came across an assertion failure during the game startup. The exact error message is:
It triggers as soon as the program window is mapped, while it is still blank. I debugged the program and found that, indeed, DrawFoundation was asking for sprite 5376, while _spritecache_items is only 5120.
I was surprised to see this, but, hey, nightlies are unsupported. So I thought it was a transient problem, and decided to wait for the next nightly. The next nightly didn't compile either, though, so I started to look into the problem. By simple bisection, I narrowed the problem to somewhere between nightlies r11430 and r11440, and further into the gap between r11431 and r11433. (Why isn't there an r11432 version?) It makes sense, as the changeset for r11433 touches lots of graphics-related things.
However, what puzzles me the most is that, r11440 being two weeks old, I haven't seen any similar report. Am I the only one having this problem? Am I missing something obvious? Any help would be appreciated, as I have absolutely no clue of what's going on. I'm pretty sure that I haven't changed anything in the compilation parameters because the configure-make-install process is scripted. I'm running linux-2.6.22 + glibc-2.7, and my compiler is gcc-4.2.2.
Also, I don't know if this is worth reporting on flyspray, particularly if I'm the only one struck by this...
Code: Select all
openttd: /tmp/OTTD-source-nightly-r11440/src/spritecache.cpp:476:
const void* GetRawSprite(SpriteID, bool): Assertion `sprite < _spritecache_items' failed.
I was surprised to see this, but, hey, nightlies are unsupported. So I thought it was a transient problem, and decided to wait for the next nightly. The next nightly didn't compile either, though, so I started to look into the problem. By simple bisection, I narrowed the problem to somewhere between nightlies r11430 and r11440, and further into the gap between r11431 and r11433. (Why isn't there an r11432 version?) It makes sense, as the changeset for r11433 touches lots of graphics-related things.
However, what puzzles me the most is that, r11440 being two weeks old, I haven't seen any similar report. Am I the only one having this problem? Am I missing something obvious? Any help would be appreciated, as I have absolutely no clue of what's going on. I'm pretty sure that I haven't changed anything in the compilation parameters because the configure-make-install process is scripted. I'm running linux-2.6.22 + glibc-2.7, and my compiler is gcc-4.2.2.
Also, I don't know if this is worth reporting on flyspray, particularly if I'm the only one struck by this...