From: Jeremy Allison Date: Thu, 12 Sep 2019 21:09:27 +0000 (-0700) Subject: s3: VFS: vfs_syncops. Implement unlinkat(). X-Git-Tag: talloc-2.3.1~627 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=83e0cf6dc9a9017232c910940a46f8d196a2e641;p=thirdparty%2Fsamba.git s3: VFS: vfs_syncops. Implement unlinkat(). This is identical to unlink(), as there are no special cases needed for rmdir(). Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- diff --git a/source3/modules/vfs_syncops.c b/source3/modules/vfs_syncops.c index 557f99bafe1..1382fdd0540 100644 --- a/source3/modules/vfs_syncops.c +++ b/source3/modules/vfs_syncops.c @@ -236,6 +236,19 @@ static int syncops_unlink(vfs_handle_struct *handle, SYNCOPS_NEXT_SMB_FNAME(UNLINK, smb_fname, (handle, smb_fname)); } +static int syncops_unlinkat(vfs_handle_struct *handle, + files_struct *dirfsp, + const struct smb_filename *smb_fname, + int flags) +{ + SYNCOPS_NEXT_SMB_FNAME(UNLINKAT, + smb_fname, + (handle, + dirfsp, + smb_fname, + flags)); +} + static int syncops_mknodat(vfs_handle_struct *handle, files_struct *dirfsp, const struct smb_filename *smb_fname, @@ -328,6 +341,7 @@ static struct vfs_fn_pointers vfs_syncops_fns = { .open_fn = syncops_open, .renameat_fn = syncops_renameat, .unlink_fn = syncops_unlink, + .unlinkat_fn = syncops_unlinkat, .symlinkat_fn = syncops_symlinkat, .linkat_fn = syncops_linkat, .mknodat_fn = syncops_mknodat,