wall: remove unnecessary warning
wall(1) may be used in scripts or in pipe. In this case report failed ttyname() does not make sense, especially if the code does not depend on on this function. Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1608176 Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
parent
f920f73d83
commit
3de236340d
|
@ -359,7 +359,6 @@ static char *makemsg(char *fname, char **mvec, int mvecsz,
|
|||
where = ttyname(STDOUT_FILENO);
|
||||
if (!where) {
|
||||
where = "somewhere";
|
||||
warn(_("cannot get tty name"));
|
||||
} else if (strncmp(where, "/dev/", 5) == 0)
|
||||
where += 5;
|
||||
|
||||
|
|
Loading…
Reference in New Issue