diff options
| author | Nakidai <nakidai@disroot.org> | 2026-01-07 00:26:37 +0300 |
|---|---|---|
| committer | Nakidai <nakidai@disroot.org> | 2026-01-07 00:26:37 +0300 |
| commit | 63c0a8860459c0c9bf3b66d4d4ec631ece4bf56e (patch) | |
| tree | e148ddc96aa7b50e3eb981eae8c9faf9de6ab2f5 /ircd.h | |
| parent | cfcb3b22245c779eb9d216c2909789e4368cce6a (diff) | |
| download | libreircd-63c0a8860459c0c9bf3b66d4d4ec631ece4bf56e.tar.gz libreircd-63c0a8860459c0c9bf3b66d4d4ec631ece4bf56e.zip | |
Fix user quit
When user A leaves, last user in the peer list B is copied into the space left by leaving A. But, besides that it also important to not forget that there can be channels containing B: they store a link to every user belonging. So, it's important to adjust all links to B iterating every channel B belongs to.
Diffstat (limited to 'ircd.h')
| -rw-r--r-- | ircd.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/ircd.h b/ircd.h index 8097c26..07bdd0f 100644 --- a/ircd.h +++ b/ircd.h @@ -75,6 +75,7 @@ extern int port; const char *getnick(const struct Peer *peer); void user_reg(struct Peer *peer, const char *nick, const char *user, const char *real); +void user_remove(size_t pid); int channel_join(struct Channel *channel, struct Peer *peer); int channel_exit(struct Channel *channel, struct Peer *peer); |