From: Anthony BOCCI Subject: Re: Fix a bug in xidle where the program was executed twice To: "tech@openbsd.org" Date: Wed, 12 Aug 2026 16:38:31 +0000 I noticed that the patch was not inline, here it is. diff --git app/xidle/xidle.c app/xidle/xidle.c index 623ca784a..62f4222b0 100644 --- app/xidle/xidle.c +++ app/xidle/xidle.c @@ -431,7 +431,7 @@ main(int argc, char **argv) * Was for real or due to terminal * switching or a locking program? */ - if (timeout > 0 && se->forced == False) + if (timeout > 0 && se->forced == False && se->state == ScreenSaverOn) action(&x, args); } break; Anthony On Wednesday, August 12th, 2026 at 10:45 AM, Anthony BOCCI wrote: > Hi, > > There is a bug in xidle that causes the program given in the -program > option to be executed twice: once when the timeout has passed, and a > second time when a mouse or keyboard event occurs. > The consequence is that when it's paired with xlock or similar, the > user needs to enter the password twice to unlock the machine. > > The bug has been described on the FreeBSD Bugzilla, and I reused > their patch here. > > https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=275761 > > Anthony