* refactoring
* send an empty batch if necessary, as per spec
* don't broadcast no-op updates
* don't trim spaces before validating the key
* bump irctest to cover metadata
* replay existing metadata to reattaching always-on clients
* use canonicalized name everywhere
* use utils.SafeErrorParam in FAIL lines
* validate key names for sub
* fix error for METADATA CLEAR
* max-keys is enforced for channels as well
* remove unlimited configurations
* maintain the limit exactly without off-by-one cases
* add final channel registration check
getPushSubscriptions() could have a stale view of the latest subscription
renewal and successful push times. We don't want to rebuild on every renewal
or every push, so add a boolean refresh argument that controls rebuilding.
* implement draft/pre-away
* clean up some subtleties in auto-away aggregation.
* consistently apply auto-away only to always-on
* `AWAY *` should not produce user-visible changes wherever possible
See 69448b13a10a14517 / #1969; the compiler can now ensure that a uint64
intended for atomic access is always aligned to a 64-bit boundary.
Convert atomic operations on uint32s and pointers as well.
AWAY status should be tracked per-session:
1. With auto-away enabled, away status is aggregated across sessions
(if any session is not away, the client is not away, else use
the away status that was set most recently)
2. With auto-away disabled, we get the legacy behavior where AWAY
applies directly to the client
checkAlwaysOnExpirationNoMutex was respecting registered status, but
always-on clients were not considered registered at the time of the
initial check, so they were being created regardless of expiration.
Store the channel-user modes of always-on clients along with their
channel memberships, restore them on server startup. This will coexist
alongside /CS AMODE, which autoapplies modes to clients on join regardless
of their always-on status.
CLIENTS LIST shows information about clients attached to a nick.
CLIENTS LOGOUT allows individual (or all) sessions to be logged out.
SESSIONS is now an alias for CLIENTS LIST.
Fixes#1072.
If force-nick-equals-account is disabled, then this could cause
a client with a non-reserved (or grouped) nick to become always-on.
(This can't happen with `/NS SET always-on true` because we check in
advance.)