Confusing code fix (#76)
* Make sure all followers are free'd before freeing the character list Otherwise, the followers structs will point to free'd memory and the stop_follower call will attempt to dereference a free'd characters' followers list. * Make sure %target% works in act triggers * code cleanup. Remove inline block, make variable names more understandable. Ref https://www.tbamud.com/forum/4-development/4525-confused-over-piece-of-code-in-parse-room
This commit is contained in:
@@ -2495,7 +2495,7 @@ void perform_act(const char *orig, struct char_data *ch, struct obj_data *obj,
|
||||
const char *i = NULL;
|
||||
char lbuf[MAX_STRING_LENGTH], *buf, *j;
|
||||
bool uppercasenext = FALSE;
|
||||
struct char_data *dg_victim = NULL;
|
||||
struct char_data *dg_victim = (to == vict_obj) ? vict_obj : NULL;
|
||||
struct obj_data *dg_target = NULL;
|
||||
char *dg_arg = NULL;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user