Pircbot Patch: We are not connected to server if there's nothing to read from the server

This commit is contained in:
Sebastian Kaspari 2010-04-14 19:24:39 +02:00
parent c3fe7963a2
commit ec9b00fd22
1 changed files with 4 additions and 1 deletions

View File

@ -208,7 +208,10 @@ public abstract class PircBot implements ReplyConstants {
}
}
this.setNick(nick);
}
if (line == null) {
throw new IOException("Could not connect to server");
}
// This makes the socket timeout on read operations after 5 minutes.