![]() |
#1 |
Rookie
Join Date: Mar 2012
Posts: 13
![]() |
bug - crash with tons of traps detected
Using revision d1db92e30511af698cc55b284693a5f928fca67a (with a savefile that was generated along different versions), I get a crash on loading the savefile (available on request). The game first crashed on using a rod of detection near a large vault.
Backtrace: Code:
#0 0x002ef4ee in fread () from /lib/tls/i686/cmov/libc.so.6 #1 0x0818653d in file_read (f=0x825687c, buf=0xbffff3e0 "traps", n=28) at z-file.c:513 #2 0x080d7bf5 in try_load (f=0x825687c) at savefile.c:472 #3 0x080d7ec1 in savefile_load (path=0x8200760 "~/.angband/Angband-v4/save/1000.Username") at savefile.c:555 #4 0x08064bc6 in play_game () at dungeon.c:1621 #5 0x0818d73e in main (argc=1, argv=0xbffff574) at main.c:457 |
![]() |
![]() |
#2 |
Swordsman
Join Date: Feb 2008
Location: Boston, MA
Posts: 250
![]() |
Thank you for the report! Are you saying that the game crashed when you used the rod of detection, and now that savefile just crashes when you try to load it? Also, was the vault on the dungeon level that you started on right after updating to that revision?
|
![]() |
![]() |
#3 |
Rookie
Join Date: Mar 2012
Posts: 13
![]() |
Yes, it segfaulted while showing the "you detect traps" message. And yes, it segfaults on start, after pressing any key on the title screen (when save loading runs). Once, on a fluke, I was 'stepi'-ing in gdb around the crash point and the game was able to load, but crashed when I used an upstair.
As for whether the vault was created in latest revision, I believe I was playing with rev 81b526d8e4 (might be a bit earlier, sorry for imprecision), went down a stair, detected and got a crash. Then I updated to see if that would fix the crash, which didn't happen. |
![]() |
![]() |
#4 |
Swordsman
Join Date: Feb 2008
Location: Boston, MA
Posts: 250
![]() |
Hmm. Well, why don't you post the savefile here and I'll take a look.
|
![]() |
![]() |
#5 |
Rookie
Join Date: Mar 2012
Posts: 13
![]() |
Thanks, here it is.
|
![]() |
![]() |
#6 |
Swordsman
Join Date: Feb 2008
Location: Boston, MA
Posts: 250
![]() |
Are you building from source? If so, can you make the following changes and recompile:
1. Add trap.txt to the Makefile in lib/edit. 2. Change line 36 of slay.c, replacing 257 with 513. With those changes, I am able to load your savefile. It seems that the slay cache was running out of room, leading (I think) to an array index out of bounds. |
![]() |
![]() |
#7 | |
Angband Devteam member
|
Quote:
__________________
"Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles |
|
![]() |
![]() |
#8 |
Rookie
Join Date: Mar 2012
Posts: 13
![]() |
Thanks, Gabe.
I'm building from source, but with your changes it still crashes the same way (same backtrace on gdb). I'm using a 32bit linux (ubuntu 10.04) and, since the crash happens in libc ("fread () from /lib/tls/i686/cmov/libc", see gdb output above), it might be hard to reproduce on other platforms. |
![]() |
![]() |
#9 | |
Swordsman
Join Date: Feb 2008
Location: Boston, MA
Posts: 250
![]() |
Quote:
The only other guess I have is that it has something to do with displaying items on trap squares (though again, I haven't had problems with this on my end, using Windows 7). If you're up for a little detective work, you could try the following: 1. Do Ctrl-a, c, z, P to create a scroll of trap detection. 2. Read the scroll. 3. Drop a bunch of items (without moving). If everything is working correctly, whenever an item drops onto a known trap square, it should show up as a red &. |
|
![]() |
![]() |
#10 |
Rookie
Join Date: Mar 2012
Posts: 13
![]() |
Items on traps display fine. OTOH, using the debug mode to create a lvl50 character and teleporting to large-vault-depth gets crashy quick, sometimes even before detecting traps.
You say my save file works OK for you? Because I'm starting to suspect the crash could have led to an inconsistent save file 'traps' entry. |
![]() |
Tags |
crash, traps |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Crash bug | Jungle_Boy | v4 | 12 | October 30, 2011 23:22 |
Crash bug in V3.3.1 | awldune | Development | 3 | October 10, 2011 14:22 |
Crash bug | Napsterbater | Vanilla | 6 | February 26, 2011 10:56 |
Crash Bug? | Rizwan | Vanilla | 4 | February 25, 2010 13:58 |
[FA] Crash Bug | Zikke | Variants | 8 | February 19, 2009 05:20 |