--- a/alix-leds.c +++ b/alix-leds.c @@ -1022,7 +1022,7 @@ int main(int argc, char **argv) #ifndef DEBUG if (pidname) { - pidfd = open(pidname, O_WRONLY|O_CREAT|O_TRUNC); + pidfd = open(pidname, O_WRONLY|O_CREAT|O_TRUNC, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH); if (pidfd < 0) die(-4, "Failed to open pidfile"); }