From: Jeremy Allison Date: Fri, 30 Aug 2019 21:10:47 +0000 (-0700) Subject: s3: torture: Change cmd_symlink to call SMB_VFS_SYMLINKAT(). X-Git-Tag: tevent-0.10.1~15 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1354f2f5210879466c706b8b2fb902bcef32da1f;p=thirdparty%2Fsamba.git s3: torture: Change cmd_symlink to call SMB_VFS_SYMLINKAT(). Use conn->cwd_fsp as current fsp. No logic change for now. Signed-off-by: Jeremy Allison Reviewed-by: Ralph Böhme --- diff --git a/source3/torture/cmd_vfs.c b/source3/torture/cmd_vfs.c index e9409d81de8..c51673acd7c 100644 --- a/source3/torture/cmd_vfs.c +++ b/source3/torture/cmd_vfs.c @@ -1157,6 +1157,7 @@ static NTSTATUS cmd_lock(struct vfs_state *vfs, TALLOC_CTX *mem_ctx, int argc, c static NTSTATUS cmd_symlink(struct vfs_state *vfs, TALLOC_CTX *mem_ctx, int argc, const char **argv) { + int ret; struct smb_filename *new_smb_fname = NULL; if (argc != 3) { @@ -1170,7 +1171,11 @@ static NTSTATUS cmd_symlink(struct vfs_state *vfs, TALLOC_CTX *mem_ctx, int argc if (new_smb_fname == NULL) { return NT_STATUS_NO_MEMORY; } - if (SMB_VFS_SYMLINK(vfs->conn, argv[1], new_smb_fname) == -1) { + ret = SMB_VFS_SYMLINKAT(vfs->conn, + argv[1], + vfs->conn->cwd_fsp, + new_smb_fname); + if (ret == -1) { printf("symlink: error=%d (%s)\n", errno, strerror(errno)); return NT_STATUS_UNSUCCESSFUL; }