1
0
mirror of https://github.com/irssi/irssi.git synced 2024-09-29 04:45:57 -04:00

put back ircnet -> chatnet backwards compatibility, this time modify

the config file to use chatnet so after .98 we could remove this


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1016 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2000-12-19 17:47:33 +00:00 committed by cras
parent db2c620951
commit 99b29df17c
2 changed files with 14 additions and 0 deletions

View File

@ -50,6 +50,13 @@ static CHANNEL_SETUP_REC *channel_setup_read(CONFIG_NODE *node)
rec->autojoin = config_node_get_bool(node, "autojoin", FALSE);
rec->name = g_strdup(channel);
rec->chatnet = g_strdup(config_node_get_str(node, "chatnet", NULL));
if (rec->chatnet == NULL) /* FIXME: remove this after .98... */ {
rec->chatnet = g_strdup(config_node_get_str(node, "ircnet", NULL));
if (rec->chatnet != NULL) {
iconfig_node_set_str(node, "chatnet", rec->chatnet);
iconfig_node_set_str(node, "ircnet", NULL);
}
}
rec->password = (password == NULL || *password == '\0') ? NULL : g_strdup(password);
rec->botmasks = (botmasks == NULL || *botmasks == '\0') ? NULL : g_strdup(botmasks);
rec->autosendcmd = (autosendcmd == NULL || *autosendcmd == '\0') ? NULL : g_strdup(autosendcmd);

View File

@ -314,6 +314,13 @@ static SERVER_SETUP_REC *server_setup_read(CONFIG_NODE *node)
rec = NULL;
chatnet = config_node_get_str(node, "chatnet", NULL);
if (chatnet == NULL) /* FIXME: remove this after .98... */ {
chatnet = config_node_get_str(node, "ircnet", NULL);
if (chatnet != NULL) {
iconfig_node_set_str(node, "chatnet", chatnet);
iconfig_node_set_str(node, "ircnet", NULL);
}
}
signal_emit("server setup read", 3, &rec, node,
chatnet == NULL ? NULL : chatnet_find(chatnet));
if (rec == NULL) {