Welcome to the Builder Academy

Question Possible Problem With New Group System

More
07 Jan 2013 14:59 - 07 Jan 2013 15:00 #1258 by zusuk
I would need Liko or someone who has also installed Vatiken's new group system to verify whether this bug is stock, I presumed it to be a stock bug because I haven't touched any of the elements involved with it.

How to replicate bug:
Make a test-character, have him animate dead a bunch of followers and make sure they are all groupped. Have a spell that can kill the test-character and all of his followers in one shot, the result should crash it.
Another way to replicate the bug is to have test-character groupped with a bunch of his charmies. Let test-character get killed and then purge the room of his charmies immediately after.

Example below:
Code:
[ 3005] The Temple Square [ None ] ( None ) You are standing on the temple square. Huge marble steps lead up to the temple gate. The entrance to the Clerics' Guild is to the west, and the old Grunting Boar Inn, is to the east. Just south of here you see the market square, the center of Midgen. [ Exits: N E S W ] [3035] A large fountain carved from blue-streaked marble is here, bubbling merrily. [41] (group) A dire badger is standing here. [41] (group) A dire badger is standing here. [41] (group) A dire badger is standing here. [41] (group) A dire badger is standing here. [41] (group) A dire badger is standing here. (leader) [Humn] Testchar the Knower of Hidden Things is standing here. 28742/28742H 5000/5000V > [ Auto zone reset: <*> Sanctus II (Zone 2) ] 28742/28742H 5000/5000V > kill testchar You stumble your attack... You miss Testchar by an inch, curse that brat! 28742/28742H 5000/5000V > A dire badger assists Testchar. A dire badger tries to bite you but bites her tongue instead! A dire badger assists Testchar. A dire badger tries to bite you but bites her tongue instead! A dire badger assists Testchar. A dire badger tries to bite you but bites her tongue instead! A dire badger assists Testchar. A dire badger tries to bite you but bites her tongue instead! A dire badger assists Testchar. A dire badger tries to bite you but bites her tongue instead! You duck under Testchar's fist as he takes a swing at you. [oCrit]You absorb all the damage! You duck under Testchar's fist as he takes a swing at you. [DF][OW][crit][140] You nearly kill Testchar with your deadly slash!! {T:58+D:8>=AC:9}[DF][65] You beautifully slash Testchar into two parts -- both dead. Testchar is dead! R.I.P. You receive one lousy experience point. [ Testchar killed by Zusuk at The Temple Square ] A dire badger realizes that Testchar is a jerk! A dire badger realizes that Testchar is a jerk! A dire badger realizes that Testchar is a jerk! A dire badger realizes that Testchar is a jerk! A dire badger realizes that Testchar is a jerk! Your blood freezes as you hear Testchar's death cry. You don't have a corpse. 28742/28742H 5000/5000V > purge The world seems a little cleaner. 28742/28742H 5000/5000V > <=========***** CRASHES HERE

Here is the GDB result:

Code:
Program received signal SIGSEGV, Segmentation fault. remove_iterator (pIterator=0xbffeaaf8) at lists.c:172 172 pIterator->pList->iIterators--; (gdb) list 167 if (pIterator->pList == NULL) { 168 mudlog(NRM, LVL_GOD, TRUE, "SYSERR: Attempting to remove iterator from NULL list."); 169 return; 170 } 171 172 pIterator->pList->iIterators--; 173 pIterator->pList = NULL; 174 pIterator->pItem = NULL; 175 } 176 (gdb) up #1 0x0810ddf0 in free_group (group=0x93f48c8) at handler.c:1489 1489 remove_iterator(&Iterator); (gdb) list 1484 for (tch = (struct char_data *) merge_iterator(&Iterator, group->members); 1485 tch; 1486 tch = next_in_list(&Iterator)) 1487 leave_group(tch); 1488 1489 remove_iterator(&Iterator); 1490 1491 free_list(group->members); 1492 remove_from_list(group, group_list); 1493 free(group); (gdb) up #2 0x0810deab in leave_group (ch=0x94555c0) at handler.c:1529 1529 free_group(group); (gdb) list 1524 1525 if (GROUP_LEADER(group) == ch && group->members->iSize) { 1526 group->leader = (struct char_data *) random_from_list(group->members); 1527 send_to_group(NULL, group, "%s has assumed leadership of the group.\r\n", GET_NAME(GROUP_LEADER(group))); 1528 } else if (group->members->iSize == 0) 1529 free_group(group); 1530 } 1531 1532 1533 void join_group(struct char_data *ch, struct group_data *group) (gdb) up #3 0x0810fbfa in extract_char_final (ch=0x94555c0) at handler.c:971 971 leave_group(ch); (gdb) list 966 if (RIDING(ch) || RIDDEN_BY(ch)) 967 dismount_char(ch); 968 969 /* Check to see if we are grouped! */ 970 if (GROUP(ch)) 971 leave_group(ch); 972 973 /* transfer objects to room, if any */ 974 while (ch->carrying) { 975 obj = ch->carrying; (gdb) up #4 0x0810ff41 in extract_pending_chars () at handler.c:1074 1074 extract_char_final(vict); (gdb) list 1069 /* Last non-free'd character to continue chain from. */ 1070 prev_vict = vict; 1071 continue; 1072 } 1073 1074 extract_char_final(vict); 1075 extractions_pending--; 1076 1077 if (prev_vict) 1078 prev_vict->next = next_vict; (gdb)

Website
www.luminariMUD.com

Main Game Port
luminariMUD.com:4100
Last edit: 07 Jan 2013 15:00 by zusuk.

Please Log in or Create an account to join the conversation.

More
08 Jan 2013 03:51 #1259 by Vatiken
What version do you have? There was a known crash bug in version 1.0 but it was fixed in 1.12.

tbaMUD developer/programmer

Please Log in or Create an account to join the conversation.

More
08 Jan 2013 07:02 #1261 by zusuk
It is version 1.2, I actually wrote it down in the comments :P

I just now read in the snippet area that you wrote it isn't compatible with 3.63 unless its revision 306 or later. And I started with 3.63 without any updates from the revisions.

Do you know off the top of your head what I will need to update? What revision # is the raw 3.63 that is available for download in the 'download' section?

What I think I'm going to have to do is do a DIFF between the latest revision and 3.63-raw and hand-patch all them.

Website
www.luminariMUD.com

Main Game Port
luminariMUD.com:4100

Please Log in or Create an account to join the conversation.

More
10 Jan 2013 08:49 #1266 by zusuk
OK, so I hand-patched all revisions made from revision 312 of stock tba to current.

And I'm positive I have group system 1.2

Any other ideas what could be causing this error?

I get the same exact crash even after the update to the codebase.

Website
www.luminariMUD.com

Main Game Port
luminariMUD.com:4100

Please Log in or Create an account to join the conversation.

More
10 Jan 2013 17:42 #1267 by zusuk
I went ahead and took an unmodified stock tbamud fresh from the SVN (so its the latest version) and patched the group code. I can confirm its a bug with the group system, even on purely stock code.

Website
www.luminariMUD.com

Main Game Port
luminariMUD.com:4100

Please Log in or Create an account to join the conversation.

More
13 Jan 2013 05:17 #1278 by Vatiken
Code:
void free_group(struct group_data * group) { struct char_data *tch; struct iterator_data Iterator; - if (group->members->iSize) + if (group->members->iSize) { for (tch = (struct char_data *) merge_iterator(&Iterator, group->members); tch; tch = next_in_list(&Iterator)) leave_group(tch); remove_iterator(&Iterator); + } free_list(group->members); remove_from_list(group, group_list); free(group); }

Try that...

tbaMUD developer/programmer
The following user(s) said Thank You: zusuk

Please Log in or Create an account to join the conversation.

Time to create page: 0.193 seconds