lxc-monitord.log should not be created with mode 0666

lxc_monitord_spawn() in src/lxc/monitor.c contained "umask(0);", and
because of this, lxc-monitord created lxc-monitord.log with mode 0666.
World-writeable log files are bad, so remove this umask(0).

Signed-off-by: Robert Vogelgesang <vogel@users.sourceforge.net>
Acked-by: Dwight Engen <dwight.engen@oracle.com>
Acked-by: Stéphane Graber <stgraber@ubuntu.com>
This commit is contained in:
Robert Vogelgesang 2014-01-28 12:01:54 +01:00 committed by Stéphane Graber
parent 1bdedfacc2
commit a27ed52b34

View File

@ -325,7 +325,6 @@ int lxc_monitord_spawn(const char *lxcpath)
exit(EXIT_SUCCESS);
}
umask(0);
if (setsid() < 0) {
SYSERROR("failed to setsid");
exit(EXIT_FAILURE);