]> git.ipfire.org Git - thirdparty/util-linux.git/commit
wall: use xgetlogin.
authorÉrico Nogueira <erico.erc@gmail.com>
Wed, 28 Jul 2021 02:51:34 +0000 (23:51 -0300)
committerÉrico Nogueira <erico.erc@gmail.com>
Thu, 29 Jul 2021 12:58:19 +0000 (09:58 -0300)
commit11109352d4a3fb34ecfdb120cca65640bcecf5b2
tree7d30de6cec9eed02c797f4886af805f040053a35
parent3386b92e09e8a945cb071808e012e0b600f8bcb2
wall: use xgetlogin.

getlogin(3) shouldn't be used for identification here. This also removes
the bug where a missing entry for getuid() in passwd database wouldn't
print a warning, because whom would be set to "???".

For consistency, switch to "<someone>" when pw look up fails.

Signed-off-by: Érico Nogueira <erico.erc@gmail.com>
term-utils/wall.c