From cac73a51a341aff34531fa0da31e8078a9a5e147 Mon Sep 17 00:00:00 2001 From: Yana Stamcheva Date: Thu, 13 Sep 2007 12:41:42 +0000 Subject: IRC server messages enhancements --- .../sip/communicator/impl/protocol/irc/IrcStack.java | 17 ++++++++++++----- .../protocol/irc/ProtocolProviderServiceIrcImpl.java | 4 ++-- 2 files changed, 14 insertions(+), 7 deletions(-) (limited to 'src') diff --git a/src/net/java/sip/communicator/impl/protocol/irc/IrcStack.java b/src/net/java/sip/communicator/impl/protocol/irc/IrcStack.java index bd71560..9ebd2ac 100644 --- a/src/net/java/sip/communicator/impl/protocol/irc/IrcStack.java +++ b/src/net/java/sip/communicator/impl/protocol/irc/IrcStack.java @@ -1153,11 +1153,17 @@ public class IrcStack + " Response : " + response); + int delimiterIndex = response.indexOf(':'); + + if(delimiterIndex != -1 && delimiterIndex < response.length() - 1) + response = response.substring(delimiterIndex + 1); + MessageIrcImpl message - = new MessageIrcImpl( response, - MessageIrcImpl.DEFAULT_MIME_TYPE, - MessageIrcImpl.DEFAULT_MIME_ENCODING, - null); + = new MessageIrcImpl( + response, + MessageIrcImpl.DEFAULT_MIME_TYPE, + MessageIrcImpl.DEFAULT_MIME_ENCODING, + null); ChatRoomIrcImpl serverRoom = (ChatRoomIrcImpl) ircMUCOpSet.getSystemRoom(); @@ -1173,7 +1179,8 @@ public class IrcStack sourceMember = new ChatRoomMemberIrcImpl(parentProvider, serverRoom, - "", + parentProvider.getAccountID() + .getService(), "", "", ChatRoomMemberRole.GUEST); diff --git a/src/net/java/sip/communicator/impl/protocol/irc/ProtocolProviderServiceIrcImpl.java b/src/net/java/sip/communicator/impl/protocol/irc/ProtocolProviderServiceIrcImpl.java index ca31350..dff0258 100644 --- a/src/net/java/sip/communicator/impl/protocol/irc/ProtocolProviderServiceIrcImpl.java +++ b/src/net/java/sip/communicator/impl/protocol/irc/ProtocolProviderServiceIrcImpl.java @@ -454,8 +454,8 @@ public class ProtocolProviderServiceIrcImpl * @param currentRegistrationState the new registration state to set */ protected void setCurrentRegistrationState( - RegistrationState currentRegistrationState) + RegistrationState regState) { - this.currentRegistrationState = currentRegistrationState; + this.currentRegistrationState = regState; } } \ No newline at end of file -- cgit v1.1