summaryrefslogtreecommitdiff
path: root/src/core/chat-commands.c
diff options
context:
space:
mode:
authorTimo Sirainen <cras@irssi.org>2002-08-09 11:17:31 +0000
committercras <cras@dbcabf3a-b0e7-0310-adc4-f8d773084564>2002-08-09 11:17:31 +0000
commit2ad623acd0ae1e5bca04fd2e21cfc0749c46059c (patch)
tree4921661c07c0c257b0c42d451e326314d8d43215 /src/core/chat-commands.c
parent452db286da579b163b65d964c452c0d73de21637 (diff)
downloadirssi-2ad623acd0ae1e5bca04fd2e21cfc0749c46059c.zip
/DISCONNECT <tag> works again for not-yet-connected servers.
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2874 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'src/core/chat-commands.c')
-rw-r--r--src/core/chat-commands.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/core/chat-commands.c b/src/core/chat-commands.c
index cc44a213..4bc931dc 100644
--- a/src/core/chat-commands.c
+++ b/src/core/chat-commands.c
@@ -245,8 +245,11 @@ static void cmd_disconnect(const char *data, SERVER_REC *server)
if (!cmd_get_params(data, &free_arg, 2 | PARAM_FLAG_GETREST, &tag, &msg))
return;
- if (*tag != '\0' && strcmp(tag, "*") != 0)
+ if (*tag != '\0' && strcmp(tag, "*") != 0) {
server = server_find_tag(tag);
+ if (server == NULL)
+ server = server_find_lookup_tag(tag);
+ }
if (server == NULL) cmd_param_error(CMDERR_NOT_CONNECTED);
if (*msg == '\0') msg = (char *) settings_get_str("quit_message");