diff options
Diffstat (limited to 'src/map/guild.c')
-rw-r--r-- | src/map/guild.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/map/guild.c b/src/map/guild.c index d0d7f14dd..ea9c3795f 100644 --- a/src/map/guild.c +++ b/src/map/guild.c @@ -477,8 +477,11 @@ int guild_recv_info(struct guild *sg) // イベントの発生 if( (ev=numdb_search(guild_infoevent_db,sg->guild_id))!=NULL ){ numdb_erase(guild_infoevent_db,sg->guild_id); - for(;ev;ev2=ev->next,aFree(ev),ev=ev2){ + while(ev){ npc_event_do(ev->name); + ev2=ev->next; + aFree(ev); + ev=ev2; } } @@ -1400,8 +1403,11 @@ int guild_castledataloadack(int castle_id,int index,int value) } if( (ev=numdb_search(guild_castleinfoevent_db,code))!=NULL ){ numdb_erase(guild_castleinfoevent_db,code); - for(;ev;ev2=ev->next,aFree(ev),ev=ev2){ + while(ev){ npc_event_do(ev->name); + ev2=ev->next; + aFree(ev); + ev=ev2; } } return 1; |