PircBot Patch: Fixed parsing NICK messages without hostmasks - fixes issue 8

This commit is contained in:
Sebastian Kaspari 2010-04-17 22:46:46 +02:00
parent 17c11c2c9a
commit 482a0bc7b5
1 changed files with 8 additions and 1 deletions

View File

@ -235,7 +235,8 @@ public abstract class PircBot implements ReplyConstants {
}
this.setNick(nick);
}
// XXX: PircBot patch - We are not connected to server if nothing received
if (line == null) {
throw new IOException("Could not connect to server");
}
@ -902,6 +903,12 @@ public abstract class PircBot implements ReplyConstants {
// (or maybe a NOTICE or suchlike from the server)
sourceNick = senderInfo;
target = token;
// XXX: PircBot Patch - (Needed for BIP IRC Proxy)
// If this is a JOIN command, use next token as target
if (command.equalsIgnoreCase("nick")) {
target = tokenizer.nextToken();
}
}
}
else {