From 4c8a09cc45d03897a473c270fede699a0420a483 Mon Sep 17 00:00:00 2001 From: Hauke Mehrtens Date: Thu, 17 Dec 2020 13:54:04 +0100 Subject: [PATCH] tools: Set mode for new file /tmp/mt76-test-%s Set the file system mode for the newly created file /tmp/mt76-test-%s, this is mandatory according to the man page and fixes a compile error with glibc. Signed-off-by: Hauke Mehrtens --- tools/eeprom.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/eeprom.c b/tools/eeprom.c index a57a9b09..68ad8d06 100644 --- a/tools/eeprom.c +++ b/tools/eeprom.c @@ -77,7 +77,7 @@ mt76_eeprom_create_file(void) return -1; } - fd = open(eeprom_file, O_RDWR | O_CREAT | O_EXCL); + fd = open(eeprom_file, O_RDWR | O_CREAT | O_EXCL, 00644); if (fd < 0) goto out;