From 7db734bba862c838ecf3c88af619dbb531ecb91e Mon Sep 17 00:00:00 2001 From: Stas Kelvich Date: Fri, 10 Jul 2020 17:27:27 +0300 Subject: [PATCH] fix tty file permissions Signed-off-by: Stas Kelvich --- src/lib/uart_emul.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/uart_emul.c b/src/lib/uart_emul.c index 778eb577..e4ab0cc8 100644 --- a/src/lib/uart_emul.c +++ b/src/lib/uart_emul.c @@ -761,7 +761,7 @@ uart_set_backend(struct uart_softc *sc, const char *backend, const char *devname perror("unlinking autopty file"); goto err; } - int namefd = open(linkname, O_CREAT | O_WRONLY); + int namefd = open(linkname, O_CREAT | O_WRONLY, 0644); if (namefd == -1) { perror("creating autopty file"); goto err;