Make sure we reset the umask on the error path

This commit is contained in:
Guido Günther 2011-03-09 14:19:56 +01:00
parent 9516a0eca3
commit a236732ec3

View File

@ -603,6 +603,7 @@ static int qemudListenUnix(struct qemud_server *server,
if (bind(sock->fd, &sock->addr.data.sa, sock->addr.len) < 0) {
VIR_ERROR(_("Failed to bind socket to '%s': %s"),
path, virStrerror(errno, ebuf, sizeof ebuf));
umask(oldmask);
goto cleanup;
}
umask(oldmask);