From 5ca6022c40792a839c62f370c2671d802811f383 Mon Sep 17 00:00:00 2001 From: skotlex Date: Tue, 6 Feb 2007 17:17:26 +0000 Subject: - Fixed char-server not sending party status update when a member logs on/off - Fixed crash when parsing guild member information change from the char-server when the specified character is not found in the guild. - Fixed MvP mobs giving exp when killed even if they shouldn't git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9802 54d463be-8e91-2dee-dedb-b68131a5f0ec --- src/map/atcommand.c | 3 ++- src/map/intif.c | 2 ++ src/map/mob.c | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) (limited to 'src/map') diff --git a/src/map/atcommand.c b/src/map/atcommand.c index 68b1909d0..7304990d6 100644 --- a/src/map/atcommand.c +++ b/src/map/atcommand.c @@ -9861,7 +9861,8 @@ int atcommand_fakename(const int fd, struct map_session_data* sd, const char* co return 0; } - memcpy(sd->fakename,name,NAME_LENGTH-1); + memcpy(sd->fakename,name,NAME_LENGTH); + sd->fakename[NAME_LENGTH-1] = '\0'; clif_charnameack(0, &sd->bl); clif_displaymessage(sd->fd,"Fake name enabled."); diff --git a/src/map/intif.c b/src/map/intif.c index ad749d5f9..d53d6b8f2 100644 --- a/src/map/intif.c +++ b/src/map/intif.c @@ -1267,6 +1267,8 @@ int intif_parse_GuildMemberInfoChanged(int fd) if( g==NULL ) return 0; idx=guild_getindex(g,account_id,char_id); + if (idx == -1) + return 0; switch(type){ case GMI_POSITION: g->member[idx].position=dd; diff --git a/src/map/mob.c b/src/map/mob.c index 7434aae3a..2d8c2591b 100644 --- a/src/map/mob.c +++ b/src/map/mob.c @@ -2058,7 +2058,7 @@ int mob_dead(struct mob_data *md, struct block_list *src, int type) double exp; //mapflag: noexp check [Lorky] - if (map[m].flag.nobaseexp || !(type&2)) + if (map[m].flag.nobaseexp || type&2) exp =1; else { exp = md->db->mexp; -- cgit v1.2.3-70-g09d2