summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormekolat <mekolat@users.noreply.github.com>2017-10-22 12:11:28 -0400
committerGitHub <noreply@github.com>2017-10-22 12:11:28 -0400
commitdaf1c49458079c645b8d45e8a4effa0260909fee (patch)
treeaa6341fc74e87b6709100ac74819f05c224e0b0e
parentf7dfa7af3afb86ad6d3dd9dd8ccbf660226b5ddb (diff)
parent3cf3ae0dbf7a6759ffd205073bcfb0d855e7727c (diff)
downloadhercules-daf1c49458079c645b8d45e8a4effa0260909fee.tar.gz
hercules-daf1c49458079c645b8d45e8a4effa0260909fee.tar.bz2
hercules-daf1c49458079c645b8d45e8a4effa0260909fee.tar.xz
hercules-daf1c49458079c645b8d45e8a4effa0260909fee.zip
Merge pull request #1886 from MishimaHaruna/fix-logmes
Fix an incorrect null check in BUILDIN(logmes)
-rw-r--r--src/map/script.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/map/script.c b/src/map/script.c
index d2101d21f..1bbffa20e 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -15866,11 +15866,12 @@ enum logmes_type {
/*==========================================
* Allows player to write logs (i.e. Bank NPC, etc) [Lupus]
*------------------------------------------*/
-BUILDIN(logmes) {
+BUILDIN(logmes)
+{
const char *str = script_getstr(st, 2);
struct map_session_data *sd = script->rid2sd(st);
enum logmes_type type = LOGMES_NPC;
- nullpo_retr(sd, false);
+ nullpo_retr(false, sd);
if (script_hasdata(st, 3)) {
type = script_getnum(st, 3);