I've been recieving a wierd crash bug lately. I have checked in my nicowar code, and I never modify this variable at all, I'm not sure what other code does execute it. Apparently the Building::owner variable of some building is being incremented. Its occurred several times while testing Nicowar. Here is a complete gdb output:
glob2: Game.cpp:1200: void Game::syncStep(Sint32): Assertion `b->owner==teams[t]' failed. Program received signal SIGABRT, Aborted. [Switching to Thread 46912507983296 (LWP 7052)] 0x0000003f1b12f280 in raise () from /lib64/libc.so.6 (gdb) bt #0 0x0000003f1b12f280 in raise () from /lib64/libc.so.6 #1 0x0000003f1b130750 in abort () from /lib64/libc.so.6 #2 0x0000003f1b1282e6 in __assert_fail () from /lib64/libc.so.6 #3 0x000000000047c2bd in Game::syncStep (this=0x7fffffdb6ed0, localTeam=0) at Game.cpp:1200 #4 0x0000000000471870 in Engine::run (this=0x7fffffdb6ed0) at Engine.cpp:448 #5 0x00000000004a7664 in Glob2::run (this=0x7fffffdba8bf, argc=1, argv=0x7fffffdba9a8) at Glob2.cpp:306 #6 0x00000000004a7c73 in main (argc=1, argv=0x7fffffdba9a8) at Glob2.cpp:431 (gdb) print b->owner->teamNumber Attempt to extract a component of a value that is not a structure pointer. (gdb) frame 3 #3 0x000000000047c2bd in Game::syncStep (this=0x7fffffdb6ed0, localTeam=0) at Game.cpp:1200 1200 assert(b->owner==teams[t]); (gdb) print b->owner->teamNumber $1 = 16777216 (gdb) print t $2 = 1 (gdb) print b $3 = (Building *) 0x2019f80 (gdb) print i $4 = 11 (gdb) print b->hp $5 = 100 (gdb) print b->type->shortTypeNum $6 = 1 (gdb) print b->typeNum $7 = 3 (gdb) print b->posX $8 = 85 (gdb) print b->posY $9 = 105 (gdb) print b->owner $10 = (class Team *) 0x185e081 (gdb) print teams[t] $11 = (class Team *) 0x185e080 _______________________________________________ glob2-devel mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/glob2-devel
