summaryrefslogtreecommitdiff
path: root/source4/ntvfs
diff options
context:
space:
mode:
Diffstat (limited to 'source4/ntvfs')
-rw-r--r--source4/ntvfs/ntvfs_generic.c3
-rw-r--r--source4/ntvfs/simple/svfs_util.c11
-rw-r--r--source4/ntvfs/simple/vfs_simple.c3
3 files changed, 13 insertions, 4 deletions
diff --git a/source4/ntvfs/ntvfs_generic.c b/source4/ntvfs/ntvfs_generic.c
index def448a671..08c8b88d30 100644
--- a/source4/ntvfs/ntvfs_generic.c
+++ b/source4/ntvfs/ntvfs_generic.c
@@ -453,8 +453,7 @@ NTSTATUS ntvfs_map_fileinfo(struct request_context *req, union smb_fileinfo *inf
return NT_STATUS_OK;
case RAW_FILEINFO_INTERNAL_INFORMATION:
- info->internal_information.out.device = info2->generic.out.device;
- info->internal_information.out.inode = info2->generic.out.inode;
+ info->internal_information.out.file_id = info2->generic.out.file_id;
return NT_STATUS_OK;
case RAW_FILEINFO_EA_INFO:
diff --git a/source4/ntvfs/simple/svfs_util.c b/source4/ntvfs/simple/svfs_util.c
index a8a88cfad0..baa6f86d94 100644
--- a/source4/ntvfs/simple/svfs_util.c
+++ b/source4/ntvfs/simple/svfs_util.c
@@ -160,3 +160,14 @@ uint16 svfs_unix_to_dos_attrib(mode_t mode)
if (!(mode & S_IWUSR)) ret |= FILE_ATTRIBUTE_READONLY;
return ret;
}
+
+/*
+ build a file_id from a stat struct
+*/
+large_t svfs_file_id(struct stat *st)
+{
+ large_t ret = st->st_ino;
+ ret <<= 32;
+ ret |= st->st_dev;
+ return ret;
+}
diff --git a/source4/ntvfs/simple/vfs_simple.c b/source4/ntvfs/simple/vfs_simple.c
index 11763c93b5..c08b36fb39 100644
--- a/source4/ntvfs/simple/vfs_simple.c
+++ b/source4/ntvfs/simple/vfs_simple.c
@@ -136,8 +136,7 @@ static NTSTATUS svfs_map_fileinfo(struct request_context *req, union smb_fileinf
info->generic.out.alloc_size = st->st_blksize * st->st_blocks;
info->generic.out.nlink = st->st_nlink;
info->generic.out.directory = S_ISDIR(st->st_mode) ? 1 : 0;
- info->generic.out.device = st->st_dev;
- info->generic.out.inode = st->st_ino;
+ info->generic.out.file_id = svfs_file_id(st);
/* REWRITE: TODO stuff in here */
info->generic.out.delete_pending = 0;
info->generic.out.ea_size = 0;