diff options
author | isundil <isundill@gmail.com> | 2015-10-01 22:36:02 +0200 |
---|---|---|
committer | isundil <isundill@gmail.com> | 2015-10-01 22:36:02 +0200 |
commit | 6ca7dc68478772258dea114d29625dc2c87999f9 (patch) | |
tree | cfa0cab1545d4a429351509ee13c3bd13341df11 /src/core/channels-setup.c | |
parent | 2ad6bb12955b3e9bfa43628e6dbfc984537f8b26 (diff) | |
download | irssi-6ca7dc68478772258dea114d29625dc2c87999f9.zip |
Updated server removal
Removing network will also remove attached channels
Diffstat (limited to 'src/core/channels-setup.c')
-rw-r--r-- | src/core/channels-setup.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/core/channels-setup.c b/src/core/channels-setup.c index b2d971dd..2902ef8e 100644 --- a/src/core/channels-setup.c +++ b/src/core/channels-setup.c @@ -86,6 +86,21 @@ static void channel_setup_destroy(CHANNEL_SETUP_REC *channel) g_free(channel); } +void channel_setup_remove_chatnet(const char *chatnet) +{ + GSList *tmp, *next; + + g_return_if_fail(chatnet != NULL); + + for (tmp = setupchannels; tmp != NULL; tmp = next) { + CHANNEL_SETUP_REC *rec = tmp->data; + + next = tmp->next; + if (g_ascii_strcasecmp(rec->chatnet, chatnet) == 0) + channel_setup_remove(rec); + } +} + void channel_setup_remove(CHANNEL_SETUP_REC *channel) { channel_config_remove(channel); |