From 325f559e339444abefb74bbaea14d17531004c69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Graber?= Date: Thu, 31 Mar 2016 17:01:04 -0400 Subject: [PATCH] Failure to unload the apparmor profile isn't fatal MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If it was unloaded already somehow, then that's fine, if it can't be unloaded, then keep it loaded and we'll just replace it on next startup. Closes #1834 Signed-off-by: Stéphane Graber --- lxd/container_lxc.go | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/lxd/container_lxc.go b/lxd/container_lxc.go index 8918160287f8..a8e60370b559 100644 --- a/lxd/container_lxc.go +++ b/lxd/container_lxc.go @@ -1425,11 +1425,8 @@ func (c *containerLXC) OnStop(target string) error { return err } - // Unlock the apparmor profile - err = AAUnloadProfile(c) - if err != nil { - return err - } + // Unload the apparmor profile + AAUnloadProfile(c) // FIXME: The go routine can go away once we can rely on LXC_TARGET go func(c *containerLXC, target string, wg *sync.WaitGroup) {