Reads the physical offset only for new files.

This commit is contained in:
Andrea Mazzoleni 2014-10-03 21:28:56 +02:00
parent 0f05d40f25
commit a0c6965959
4 changed files with 58 additions and 33 deletions

View file

@ -1339,7 +1339,7 @@ int devuuid(uint64_t device, char* uuid, size_t uuid_size)
return 0;
}
int filephy(const char* file, struct stat* st, uint64_t* physical)
int filephy(const char* file, uint64_t size, uint64_t* physical)
{
HANDLE h;
STARTING_VCN_INPUT_BUFFER svib;
@ -1348,9 +1348,11 @@ int filephy(const char* file, struct stat* st, uint64_t* physical)
BOOL ret;
DWORD n;
/* in Wine just uses the inode number because FSCTL_GET_RETRIVIAL_POINTERS is not supported */
(void)size;
/* in Wine FSCTL_GET_RETRIVIAL_POINTERS is not supported */
if (is_wine) {
*physical = st->st_ino;
*physical = FILEPHY_UNREPORTED_OFFSET;
return 0;
}