diff options
author | Curtis McEnroe | 2019-07-02 18:40:06 -0400 |
---|---|---|
committer | Curtis McEnroe | 2019-07-02 18:40:06 -0400 |
commit | 906440968e658629a3722ebc8d8405cbbb7b4d1d (patch) | |
tree | 7555c879b99b4756d42bce475c53e1ed233f805c /handle.c | |
parent | 426be32b1d802cf442cc074a4a412ffa4eb6e3ad (diff) |
Add -k option for joining with keys
Diffstat (limited to 'handle.c')
-rw-r--r-- | handle.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/handle.c b/handle.c index a46c149..4f9015c 100644 --- a/handle.c +++ b/handle.c @@ -138,7 +138,11 @@ static void handleReplyWelcome(char *prefix, char *params) { self.nick = strdup(nick); if (!self.nick) err(EX_OSERR, "strdup"); } - if (self.join) ircFmt("JOIN %s\r\n", self.join); + if (self.join && self.keys) { + ircFmt("JOIN %s %s\r\n", self.join, self.keys); + } else if (self.join) { + ircFmt("JOIN %s\r\n", self.join); + } tabTouch(TagStatus, self.nick); uiLog(TagStatus, UICold, L"You have arrived"); |