summaryrefslogtreecommitdiffhomepage
path: root/src/fs
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2016-12-23 04:23:51 -0500
committermidipix <writeonce@midipix.org>2016-12-23 04:37:00 -0500
commitb061d6a1daa4e0a91c40566162547fc050ebc5c2 (patch)
tree63732f346a41ad7d28d7dfddf31c7024c92a74ac /src/fs
parent921d0b1fefd3e44a3109bb03a15ad6511dd21b32 (diff)
downloadntapi-b061d6a1daa4e0a91c40566162547fc050ebc5c2.tar.bz2
ntapi-b061d6a1daa4e0a91c40566162547fc050ebc5c2.tar.xz
__ntapi_tt_istat(): clean-up, simplify logic.
Diffstat (limited to 'src/fs')
-rw-r--r--src/fs/ntapi_tt_istat.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/fs/ntapi_tt_istat.c b/src/fs/ntapi_tt_istat.c
index a42c8dd..00766ed 100644
--- a/src/fs/ntapi_tt_istat.c
+++ b/src/fs/ntapi_tt_istat.c
@@ -30,13 +30,15 @@ int32_t __stdcall __ntapi_tt_istat(
wchar16_t * wch_mark;
uint32_t hash;
+ (void)flags;
+
/* validaton */
if (!hfile && !path)
- return NT_STATUS_INVALID_HANDLE;
+ return NT_STATUS_INVALID_PARAMETER;
/* hfile */
if (hfile) {
- istat->flags_out = 0;
+ istat->flags = 0;
} else {
/* oa */
oa.len = sizeof(nt_oa);
@@ -58,11 +60,10 @@ int32_t __stdcall __ntapi_tt_istat(
open_options | NT_FILE_SYNCHRONOUS_IO_ALERT)))
return status;
- istat->flags_out = NT_STAT_NEW_HANDLE;
+ istat->flags = NT_STAT_NEW_HANDLE;
}
- istat->hfile = hfile;
- istat->flags_in = flags;
+ istat->hfile = hfile;
/* file index number */
if ((status = __ntapi->zw_query_information_file(
@@ -112,9 +113,9 @@ int32_t __stdcall __ntapi_tt_istat(
&& (wch[9]=='u')
&& (wch[10]=='p')
&& (wch[11]=='\\')) {
- istat->flags_out |= NT_STATFS_MUP_DEVICE;
wch_mark = &wch[12];
hash = __DEVICE_MUP_PREFIX_HASH;
+ istat->flags |= NT_STATFS_MUP_DEVICE;
} else {
wch_mark = &wch[8];
hash = __DEVICE_PATH_PREFIX_HASH;