Update PhCreateFile return status for filenames
@@ -8209,7 +8209,7 @@ NTSTATUS PhCreateFile(
_Out_ PHANDLE FileHandle,
_In_ PPH_STRING FileName,
_In_ ACCESS_MASK DesiredAccess,
- _In_opt_ ULONG FileAttributes,
+ _In_ ULONG FileAttributes,
_In_ ULONG ShareAccess,
_In_ ULONG CreateDisposition,
_In_ ULONG CreateOptions
@@ -8222,7 +8222,7 @@ NTSTATUS PhCreateFile(
IO_STATUS_BLOCK isb;
if (!PhStringRefToUnicodeString(&FileName->sr, &fileName))
- return STATUS_UNSUCCESSFUL;
+ return STATUS_NAME_TOO_LONG;
InitializeObjectAttributes(
&objectAttributes,
@@ -8450,7 +8450,7 @@ NTSTATUS PhQueryFullAttributesFile(
OBJECT_ATTRIBUTES objectAttributes;
if (!PhStringRefToUnicodeString(&FileName->sr, &fileName))
- return STATUS_UNSUCCESSFUL;
+ return STATUS_NAME_TOO_LONG;
InitializeObjectAttributes(
&objectAttributes,
@@ -8509,7 +8509,7 @@ NTSTATUS PhQueryAttributesFile(
OBJECT_ATTRIBUTES objectAttributes;
if (!PhStringRefToUnicodeString(&FileName->sr, &fileName))
- return STATUS_UNSUCCESSFUL;
+ return STATUS_NAME_TOO_LONG;
InitializeObjectAttributes(
&objectAttributes,
