mirror of
https://github.com/samba-team/samba.git
synced 2025-03-04 16:58:42 +03:00
vfstest: Convert cmd_lstat to synthetic_smb_fname
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
parent
7d5403037a
commit
6624095d67
@ -749,17 +749,15 @@ static NTSTATUS cmd_lstat(struct vfs_state *vfs, TALLOC_CTX *mem_ctx, int argc,
|
|||||||
struct smb_filename *smb_fname = NULL;
|
struct smb_filename *smb_fname = NULL;
|
||||||
SMB_STRUCT_STAT st;
|
SMB_STRUCT_STAT st;
|
||||||
time_t tmp_time;
|
time_t tmp_time;
|
||||||
NTSTATUS status;
|
|
||||||
|
|
||||||
if (argc != 2) {
|
if (argc != 2) {
|
||||||
printf("Usage: lstat <path>\n");
|
printf("Usage: lstat <path>\n");
|
||||||
return NT_STATUS_OK;
|
return NT_STATUS_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
status = create_synthetic_smb_fname_split(mem_ctx, argv[1], NULL,
|
smb_fname = synthetic_smb_fname_split(mem_ctx, argv[1], NULL);
|
||||||
&smb_fname);
|
if (smb_fname == NULL) {
|
||||||
if (!NT_STATUS_IS_OK(status)) {
|
return NT_STATUS_NO_MEMORY;
|
||||||
return status;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (SMB_VFS_LSTAT(vfs->conn, smb_fname) == -1) {
|
if (SMB_VFS_LSTAT(vfs->conn, smb_fname) == -1) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user