docs: clarify smartkillclient kill fallback

Add an inline comment on the fallback branch noting that the client is
closed when it is single-tag, or when removing the viewed tag(s) would
leave it on none.
This commit is contained in:
ShadowProgr 2026-06-01 08:52:34 +07:00
parent e4c74de7df
commit e903cd99f4
No known key found for this signature in database

View file

@ -366,6 +366,8 @@ int32_t smartkillclient(const Arg *arg) {
return 0; return 0;
uint32_t newtags = c->tags & ~(c->mon->tagset[c->mon->seltags] & TAGMASK); uint32_t newtags = c->tags & ~(c->mon->tagset[c->mon->seltags] & TAGMASK);
// Kill the client if it's single-tag, or if removing the tag(s) would leave
// it on none
if (__builtin_popcount(c->tags & TAGMASK) <= 1 || !newtags) { if (__builtin_popcount(c->tags & TAGMASK) <= 1 || !newtags) {
pending_kill_client(c); pending_kill_client(c);
return 0; return 0;