From 5563a8f2030455c2ce4b85582ef27034180be38e Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Thu, 15 Nov 2001 18:37:33 +0000 Subject: [PATCH] /QUOTE and /RAWQUOTE should work as soon as the socket is connected. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2020 dbcabf3a-b0e7-0310-adc4-f8d773084564 --- src/irc/core/irc-commands.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/irc/core/irc-commands.c b/src/irc/core/irc-commands.c index a7622fd6..fd8d600e 100644 --- a/src/irc/core/irc-commands.c +++ b/src/irc/core/irc-commands.c @@ -523,7 +523,10 @@ static void cmd_sconnect(const char *data, IRC_SERVER_REC *server) /* SYNTAX: QUOTE */ static void cmd_quote(const char *data, IRC_SERVER_REC *server) { - CMD_IRC_SERVER(server); + if (server != NULL && !IS_IRC_SERVER(server)) + return; + if (server == NULL) + cmd_return_error(CMDERR_NOT_CONNECTED); irc_send_cmd(server, data); } @@ -531,7 +534,10 @@ static void cmd_quote(const char *data, IRC_SERVER_REC *server) /* SYNTAX: RAWQUOTE */ static void cmd_rawquote(const char *data, IRC_SERVER_REC *server) { - CMD_IRC_SERVER(server); + if (server != NULL && !IS_IRC_SERVER(server)) + return; + if (server == NULL) + cmd_return_error(CMDERR_NOT_CONNECTED); irc_send_cmd_full(server, data, FALSE, FALSE, TRUE); }