diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2008-05-13 14:27:33 +0200 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2008-05-13 14:27:33 +0200 |
commit | 673e4ad3bed15e26d6384103549127c56e7ce7b8 (patch) | |
tree | 8ea7dd032ceba539cd1d011e444a8e4c3d5dbca9 /src/plugins/irc | |
parent | a804fb1936ee46a86c83053f9c5647371fea64fd (diff) | |
download | weechat-673e4ad3bed15e26d6384103549127c56e7ce7b8.zip |
Disable auto-connect for plugins with command line option ("-a")
Diffstat (limited to 'src/plugins/irc')
-rw-r--r-- | src/plugins/irc/irc.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/plugins/irc/irc.c b/src/plugins/irc/irc.c index 05c4f0ea4..b850cceb4 100644 --- a/src/plugins/irc/irc.c +++ b/src/plugins/irc/irc.c @@ -85,6 +85,8 @@ irc_signal_quit_cb (void *data, char *signal, char *type_data, int weechat_plugin_init (struct t_weechat_plugin *plugin) { + char *auto_connect; + weechat_plugin = plugin; #ifdef HAVE_GNUTLS @@ -111,8 +113,10 @@ weechat_plugin_init (struct t_weechat_plugin *plugin) /* hook completions */ irc_completion_init (); - - irc_server_auto_connect (1, 0); + + auto_connect = weechat_info_get ("auto_connect"); + irc_server_auto_connect ((auto_connect && (strcmp (auto_connect, "1") == 0)) ? 1 : 0, + 0); irc_hook_timer = weechat_hook_timer (1 * 1000, 0, 0, &irc_server_timer_cb, NULL); |