Want a native logname(1)
As part of the ksh93 integration in OpenSolaris, logname(1) was made into something that linked against ksh93. Part of the reason for this was because of '6661487 logname reports nothing after running the script command' where using script(1) caused logname(1) to fail because of the fact that there was no longer a controlling tty. To make dealing with ksh93 easier, I've gone ahead and reimplemented logname(1) in a way that is compatible with ksh93's behavior in this situation. Though it would be better if we could solve the underlying getlogin(3C) problem, that's a separate problem regardless of which implementation we are using.
I've tested this by logging in as users and making sure that logname(1) matched that. I also verified that we printed something while inside of script(1) and that it behaves the same way as the current builtin.
Updated by Electric Monk over 1 year ago
- Status changed from New to Closed
commit d2505bec80a8674012fac747505ea59e02e44f48 Author: Robert Mustacchi <email@example.com> Date: 2019-12-27T15:22:32.000Z 11877 Want a native logname(1) Reviewed by: Andy Fiddaman <firstname.lastname@example.org> Approved by: Richard Lowe <email@example.com>