diff options
| author | Nakidai <nakidai@disroot.org> | 2026-02-01 21:04:07 +0300 |
|---|---|---|
| committer | Nakidai <nakidai@disroot.org> | 2026-02-01 21:04:07 +0300 |
| commit | efd4526d3043f82bf349e76031c2607d8f45a64b (patch) | |
| tree | 27534793a86b00ff67c525dedcc00a673363d67b /reply.c | |
| parent | a7298f097c6e899dfc4cd91468cd3256f024870a (diff) | |
| download | libreircd-efd4526d3043f82bf349e76031c2607d8f45a64b.tar.gz libreircd-efd4526d3043f82bf349e76031c2607d8f45a64b.zip | |
Enhance registration messages
Now ircd responds with all replies up to 4 Plus memchr was wrong, yep
Diffstat (limited to 'reply.c')
| -rw-r--r-- | reply.c | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/reply.c b/reply.c index c8d526b..2cd8c04 100644 --- a/reply.c +++ b/reply.c @@ -67,13 +67,30 @@ vreply(const struct Peer *peer, int number, va_list ap) { #define WRITE(...) writef(peer->fd, __VA_ARGS__) REPLY(1, WRITE( - ":%s 001 %s Welcome to the Internet Relay Network %s!%s@%s", + ":%s 001 %s :Welcome to the Internet Relay Network %s!%s@%s", hostname, getnick(peer), getnick(peer), peer->user, peer->host ), _); + REPLY(2, WRITE( + ":%s 002 %s :Your host is %s, running version " IRCD_VERSION, + hostname, + getnick(peer), + hostname + ), _); + REPLY(3, WRITE( + ":%s 003 %s :This server was created " CREATION_DATE, + hostname, + getnick(peer) + ), _); + REPLY(4, WRITE( + ":%s 004 %s :%s libreircd-" IRCD_VERSION " aiwroOs :", + hostname, + getnick(peer), + hostname + ), _); REPLY(221, WRITE( ":%s 221 %s +%s%s%s%s%s%s%s", hostname, |