diff options
Diffstat (limited to 'src/map/party.c')
-rw-r--r-- | src/map/party.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/map/party.c b/src/map/party.c index 551c4d56f..dbb7b6ae2 100644 --- a/src/map/party.c +++ b/src/map/party.c @@ -798,12 +798,16 @@ int party_send_logout(struct map_session_data *sd) return 1; } -int party_send_message(struct map_session_data *sd,const char *mes,int len) +int party_send_message(struct map_session_data *sd, const char *mes) { - if(sd->status.party_id==0) + int len = (int)strlen(mes); + + nullpo_ret(sd); + + if (sd->status.party_id == 0) return 0; - intif->party_message(sd->status.party_id,sd->status.account_id,mes,len); - party->recv_message(sd->status.party_id,sd->status.account_id,mes,len); + intif->party_message(sd->status.party_id, sd->status.account_id, mes, len); + party->recv_message(sd->status.party_id, sd->status.account_id, mes, len); // Chat logging type 'P' / Party Chat logs->chat(LOG_CHAT_PARTY, sd->status.party_id, sd->status.char_id, sd->status.account_id, mapindex_id2name(sd->mapindex), sd->bl.x, sd->bl.y, NULL, mes); |