From fbeaa2fc7f40999f6f6b96ab1e6b2f5de11a5d6c Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 12 Feb 2018 04:03:05 +0300 Subject: Fix messages about enabled/disabled cvc mode. --- src/map/atcommand.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/map/atcommand.c b/src/map/atcommand.c index cb6428f1f..2bcb22738 100644 --- a/src/map/atcommand.c +++ b/src/map/atcommand.c @@ -1691,7 +1691,7 @@ ACMD(cvcoff) clif->map_property_mapall(sd->bl.m, MAPPROPERTY_NOTHING); clif->maptypeproperty2(&sd->bl, ALL_SAMEMAP); map->foreachinmap(atcommand->stopattack, sd->bl.m, BL_CHAR, 0); - clif->message(fd, msg_fd(fd, 26)); // CvC: Off. + clif->message(fd, msg_fd(fd, 137)); // CvC: Off. return true; } @@ -1710,7 +1710,7 @@ ACMD(cvcon) map->list[sd->bl.m].flag.cvc = 1; clif->map_property_mapall(sd->bl.m, MAPPROPERTY_AGITZONE); clif->maptypeproperty2(&sd->bl, ALL_SAMEMAP); - clif->message(fd, msg_fd(fd, 27)); // CvC: On. + clif->message(fd, msg_fd(fd, 138)); // CvC: On. return true; } -- cgit v1.2.3-70-g09d2 From 081694ca70c7ebbd91bb1f49c58687a6cd33dfa0 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 12 Feb 2018 04:08:09 +0300 Subject: Fix possible crash in zone change code. Fixes #1971 In function map_zone_change2 silently exit if zone is NULL. --- src/map/map.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/map/map.c b/src/map/map.c index 106224a47..bb367a08d 100644 --- a/src/map/map.c +++ b/src/map/map.c @@ -4502,6 +4502,8 @@ void map_zone_change2(int m, struct map_zone_data *zone) { const char *empty = ""; + if (zone == NULL) + return; Assert_retv(m >= 0 && m < map->count); if( map->list[m].zone == zone ) return; -- cgit v1.2.3-70-g09d2