Paul Eggert wrote:
> > But, yes, that seems correct to me also.
>
> Thanks for the comments. I installed the attached and plan to propagate
> this into coreutils shortly.
And what is the "who" output that you get with this patch?
The patch looks reasonable, but I am not convinced any more that doing
modifications on the coreutils+gnulib side is the only thing we need.
Basically, we have
- an information broker, systemd-logind,
- several information providers: the login screens and terminal emulators,
- several information consumers: users of the libsystemd library, in
particular, the 'who' program.
After this infrastructure has been put in place (on our side, in 2023),
it could be that some of the information is partially nonsense:
$ who
eggert pts/0 2026-04-18 08:41 (47.154.25.11)
gdm-greeter seat0 2026-04-17 17:26
gdm-greeter tty1 2026-04-17 17:26
Were you only remotely logged in? And no one sitting at "seat0"?
I am now installing Fedora44 with 8 different desktop environments and
trying to see if the "who" output makes sense in all cases.
If some "who" output does not make sense, generally it is better to
fix the information provider, rather than to have a sanitization pass
in the information consumers. In that case, we should consider filing
bug reports with the information providers.
Bruno