diff options
author | shennetsind <ind@henn.et> | 2014-02-24 17:50:42 -0300 |
---|---|---|
committer | shennetsind <ind@henn.et> | 2014-02-24 17:50:42 -0300 |
commit | 3c87f3a57294b41a0c3c6af953a37ffcad9c8f19 (patch) | |
tree | f87fa67eb3adfd0679c47d19c66eac005c1b3cce /src/map/clif.c | |
parent | 24551d9a2d9ba7e275c4dfe940a5acb941670cc5 (diff) | |
download | hercules-3c87f3a57294b41a0c3c6af953a37ffcad9c8f19.tar.gz hercules-3c87f3a57294b41a0c3c6af953a37ffcad9c8f19.tar.bz2 hercules-3c87f3a57294b41a0c3c6af953a37ffcad9c8f19.tar.xz hercules-3c87f3a57294b41a0c3c6af953a37ffcad9c8f19.zip |
Fixed console parse gm command crash on select commands
Also fixed an issue with socket flushing
Signed-off-by: shennetsind <ind@henn.et>
Diffstat (limited to 'src/map/clif.c')
-rw-r--r-- | src/map/clif.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index 02e64aaba..425759d29 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -5587,7 +5587,7 @@ void clif_status_change(struct block_list *bl,int type,int flag,int tick,int val void clif_displaymessage(const int fd, const char* mes) { nullpo_retv(mes); - if( fd == -2 ) { + if( map->cpsd_active && fd == 0 ) { ShowInfo("HCP: %s\n",mes); } else if ( fd > 0 ) { size_t len; @@ -5619,7 +5619,7 @@ void clif_displaymessage2(const int fd, const char* mes) { size_t len = strnlen(line, 255); if (len > 0) { // don't send a void message (it's not displaying on the client chat). @help can send void line. - if( fd == -2 ) { + if( map->cpsd_active && fd == 0 ) { ShowInfo("HCP: %s\n",line); } else { WFIFOHEAD(fd, 5 + len); @@ -5638,7 +5638,7 @@ void clif_displaymessage2(const int fd, const char* mes) { void clif_displaymessage_sprintf(const int fd, const char* mes, ...) { va_list ap; - if( fd == -2 ) { + if( map->cpsd_active && fd == 0 ) { ShowInfo("HCP: "); va_start(ap,mes); _vShowMessage(MSG_NONE,mes,ap); |