diff options
author | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2008-02-04 17:24:49 +0000 |
---|---|---|
committer | ultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2008-02-04 17:24:49 +0000 |
commit | 46ca642c09468dbc52ca390c8f1d368e7ffa2966 (patch) | |
tree | 2cf0242eb3977deecba036774cb8e6d24df01627 /src/map | |
parent | 4a7c98801d7faea446738b23f9a2f59899ef7ceb (diff) | |
download | hercules-46ca642c09468dbc52ca390c8f1d368e7ffa2966.tar.gz hercules-46ca642c09468dbc52ca390c8f1d368e7ffa2966.tar.bz2 hercules-46ca642c09468dbc52ca390c8f1d368e7ffa2966.tar.xz hercules-46ca642c09468dbc52ca390c8f1d368e7ffa2966.zip |
Fixed one IRC module crash when trying to send messages when disconnected.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12174 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map')
-rw-r--r-- | src/map/irc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/map/irc.c b/src/map/irc.c index 9b1a48c5f..88ada1311 100644 --- a/src/map/irc.c +++ b/src/map/irc.c @@ -159,9 +159,9 @@ int irc_keepalive_timer(int tid, unsigned int tick, int id, int data) void irc_send(char *buf) { int len; - int fd = irc_si->fd; + int fd; - if(!irc_si || !session[fd]) + if(!irc_si || !(fd = irc_si->fd) || !session[fd]) return; len = strlen(buf) + 1; |