diff options
author | Karel Zak | 2019-05-27 13:07:12 +0200 |
---|---|---|
committer | Karel Zak | 2019-05-27 13:07:12 +0200 |
commit | 2c864ba8fcf50246920d09feaa2b02f3a3dfd52c (patch) | |
tree | e03eda273424729ccd1820ef89fbaa71c79423f0 /term-utils/mesg.1 | |
parent | lib/ttyutils: introduce get_terminal_stdfd() (diff) | |
download | kernel-qcow2-util-linux-2c864ba8fcf50246920d09feaa2b02f3a3dfd52c.tar.gz kernel-qcow2-util-linux-2c864ba8fcf50246920d09feaa2b02f3a3dfd52c.tar.xz kernel-qcow2-util-linux-2c864ba8fcf50246920d09feaa2b02f3a3dfd52c.zip |
mesg: avoid 'ttyname failed: Success' message
The ttyname(3) can fail to access /dev/ path, and that will cause function
to fail without setting errno value with result of rather confusing error
message. Lets start setting stdin permission via /proc when this happens as
a go-around, with hope kernel following symlink does not fail. Ok, noted,
that hopes of symlink follow working are pretty slim.
Based on patch from Sami Kerola <kerolasa@iki.fi>.
Reference: https://github.com/lxc/lxd/issues/1724
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'term-utils/mesg.1')
-rw-r--r-- | term-utils/mesg.1 | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/term-utils/mesg.1 b/term-utils/mesg.1 index 15c834dd7..18e7c2451 100644 --- a/term-utils/mesg.1 +++ b/term-utils/mesg.1 @@ -58,8 +58,8 @@ should be executed in your login scripts. .PP The .B mesg -utility silently exits with error status 2 if the current standard error output does -not refer to the terminal. In this case execute +utility silently exits with error status 2 if not executed on terminal. In this +case execute .B mesg is pointless. The command line option \fB\-\-verbose\fR forces mesg to print a warning in this situation. This behaviour has been introduced |