summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTimo Sirainen <cras@irssi.org>2000-05-17 09:42:31 +0000
committercras <cras@dbcabf3a-b0e7-0310-adc4-f8d773084564>2000-05-17 09:42:31 +0000
commita0aa6493682fc7b12a83352857abd3697a1ea677 (patch)
treeea89edf08a0fb41cceb0182d45f7b0d4155b3be0
parent0ce6aa720c955828b272cd086a2fd29166898dd8 (diff)
downloadirssi-a0aa6493682fc7b12a83352857abd3697a1ea677.zip
/mode #channel -k key now removes the "+k" mode too instead of just setting
the channel key to NULL. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@225 dbcabf3a-b0e7-0310-adc4-f8d773084564
-rw-r--r--src/irc/core/modes.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/irc/core/modes.c b/src/irc/core/modes.c
index 95549a4d..de4939cf 100644
--- a/src/irc/core/modes.c
+++ b/src/irc/core/modes.c
@@ -121,10 +121,9 @@ void parse_channel_modes(CHANNEL_REC *channel, const char *setby, const char *mo
ptr = cmd_get_param(&modestr);
if (*ptr != '\0' || type == '-') {
g_free_and_null(channel->key);
- if (type == '+') {
+ channel->mode_key = type == '+';
+ if (type == '+')
channel->key = g_strdup(ptr);
- channel->mode_key = TRUE;
- }
}
signal_emit("channel mode changed", 1, channel);
break;