]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commit
security: fix deadlock with prefork
authorEric Blake <eblake@redhat.com>
Fri, 19 Jul 2013 15:07:19 +0000 (09:07 -0600)
committerEric Blake <eblake@redhat.com>
Fri, 19 Jul 2013 15:15:22 +0000 (09:15 -0600)
commitbfc183c1e377b24cebf5cede4c00f3dc0d1b3486
tree4e65c3c9e3efd2e201f2935116a147c9d4d110a2
parenta81eb0b4e903a75cd0777bed2a6886fac105b4fc
security: fix deadlock with prefork

Attempts to start a domain with both SELinux and DAC security
modules loaded will deadlock; latent problem introduced in commit
fdb3bde and exposed in commit 29fe5d7.  Basically, when recursing
into the security manager for other driver's prefork, we have to
undo the asymmetric lock taken at the manager level.

Reported by Jiri Denemark, with diagnosis help from Dan Berrange.

* src/security/security_stack.c (virSecurityStackPreFork): Undo
extra lock grabbed during recursion.

Signed-off-by: Eric Blake <eblake@redhat.com>
src/security/security_stack.c