Always make sure to not acquire controlling TTY for output redirect

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
Joachim Wiberg committed 2021-05-31 10:48:04 +02:00
1 parent 4b1b3f6913
commit e18d63df4a
1 file changed
+1 -1
+1 -1
View File
@@ -138,7 +138,7 @@ static int fredirect(const char *file)
{
int fd;
fd = open(file, O_WRONLY | O_APPEND);
fd = open(file, O_WRONLY | O_APPEND | O_NOCTTY);
if (-1 != fd) {
dup2(fd, STDOUT_FILENO);
dup2(fd, STDERR_FILENO);