Changeset d63f37c


Ignore:
Timestamp:
2015-11-08T08:16:15Z (4 years ago)
Author:
dequis <dx@…>
Branches:
master
Children:
d6e2aa8
Parents:
37c9653
Message:

IRCv3 extended-join capability

Not very useful for the account features (and i won't implement
account-notify), but it has a real name field, and it's *really* easy to
implement.

Files:
3 edited

Legend:

Unmodified
Added
Removed
  • irc.h

    r37c9653 rd63f37c  
    7070        CAP_SASL = (1 << 0),
    7171        CAP_MULTI_PREFIX = (1 << 1),
     72        CAP_EXTENDED_JOIN = (1 << 2),
    7273} irc_cap_flag_t;
    7374
  • irc_cap.c

    r37c9653 rd63f37c  
    4040        {"sasl", CAP_SASL},
    4141        {"multi-prefix", CAP_MULTI_PREFIX},
     42        {"extended-join", CAP_EXTENDED_JOIN},
    4243        {NULL},
    4344};
  • irc_send.c

    r37c9653 rd63f37c  
    172172        irc_t *irc = ic->irc;
    173173
    174         irc_write(irc, ":%s!%s@%s JOIN :%s", iu->nick, iu->user, iu->host, ic->name);
     174        if (irc->caps & CAP_EXTENDED_JOIN) {
     175                irc_write(irc, ":%s!%s@%s JOIN %s * :%s", iu->nick, iu->user, iu->host, ic->name, iu->fullname);
     176        } else {
     177                irc_write(irc, ":%s!%s@%s JOIN :%s", iu->nick, iu->user, iu->host, ic->name);
     178        }
    175179
    176180        if (iu == irc->user) {
Note: See TracChangeset for help on using the changeset viewer.