summaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
authorSebastien Helleu <flashcode@flashtux.org>2009-04-07 18:12:46 +0200
committerSebastien Helleu <flashcode@flashtux.org>2009-04-07 18:12:46 +0200
commit3aeb24cf1dcfead638b14a8c855128ee7f7f45c2 (patch)
tree67aa265391d371356ee5d24666a22ae079847ab6 /src/plugins
parent564afdc75de7bb2e13bd53397f599cf6a2e6a62f (diff)
downloadweechat-3aeb24cf1dcfead638b14a8c855128ee7f7f45c2.zip
Fix crash with IRC server switch (alt-s) when no server buffer is opened
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/irc/irc-command.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/irc/irc-command.c b/src/plugins/irc/irc-command.c
index f39ce07e1..76f0b552c 100644
--- a/src/plugins/irc/irc-command.c
+++ b/src/plugins/irc/irc-command.c
@@ -3148,7 +3148,8 @@ irc_command_server (void *data, struct t_gui_buffer *buffer, int argc,
}
}
}
- irc_server_set_current_server (irc_current_server);
+ if (irc_current_server)
+ irc_server_set_current_server (irc_current_server);
}
return WEECHAT_RC_OK;
}