]> git.proxmox.com Git - mirror_lxc.git/commit
lxc-destroy: Separately rm rootfs if it is a symlink
authorSerge Hallyn <serge.hallyn@ubuntu.com>
Thu, 6 Sep 2012 02:59:13 +0000 (21:59 -0500)
committerStéphane Graber <stgraber@ubuntu.com>
Thu, 25 Oct 2012 08:27:26 +0000 (10:27 +0200)
commit55116c42e767ce795f796fc51cd2ef7d76cf18af
treec81ee3a96b3949b3b14b435dbe9a2e9b8a131104
parentb942e67226af9e690bd63ac440b99aedb6becbb3
lxc-destroy: Separately rm rootfs if it is a symlink

If rootfs is a symbolic link but not to a block device, then do a separate
rm of its contents.  We have to do this because, out of cowardice, we call
rm with --one-filesystem.

Removing the '-o -h $rootdev' is ok, because if $rootdev is a symbolic
link to a block device (including lvm blockdev) then -b will still return
true.

Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
src/lxc/lxc-destroy.in