]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
os/LFNIndex: remove alt xattr after unlink
authorSage Weil <sage@redhat.com>
Sat, 19 Jul 2014 00:28:18 +0000 (17:28 -0700)
committerSage Weil <sage@redhat.com>
Wed, 23 Jul 2014 21:48:14 +0000 (14:48 -0700)
commitec36f0a130d67df6cbeefcc9c2d83eb703b6b28c
treef508e087e6530c7f126cb9f58654adea892bfe97
parenta320c260a9e088ab0a4ea3d5298c06a2d077de37
os/LFNIndex: remove alt xattr after unlink

After we unlink, if the nlink on the inode is still non-zero, remove the
alt xattr.  We can *only* do this after the rename or unlink operation
because we don't want to leave a file system link in place without the
matching xattr; hence the fsync_dir() call.

Note that this might leak an alt xattr if we happen to fail after the
rename/unlink but before the removexattr is committed.  We'll fix that
next.

Signed-off-by: Sage Weil <sage@redhat.com>
src/os/LFNIndex.cc