[BTRFS] Reduce diff with upstream

CORE-15452
This commit is contained in:
Pierre Schweitzer 2018-12-25 13:50:07 +01:00
parent f75ea083e3
commit e6cd48809a
No known key found for this signature in database
GPG Key ID: 7545556C3D585B0B
2 changed files with 12 additions and 6 deletions

View File

@ -1856,6 +1856,11 @@ NTSTATUS NTAPI ZwQueryInformationProcess(
#endif
#endif
#if defined(__REACTOS__) && (NTDDI_VERSION < NTDDI_VISTA)
typedef struct _ECP_LIST ECP_LIST;
typedef struct _ECP_LIST *PECP_LIST;
#endif
#if defined(__REACTOS__) && (NTDDI_VERSION < NTDDI_WIN7)
NTSTATUS WINAPI RtlUnicodeToUTF8N(CHAR *utf8_dest, ULONG utf8_bytes_max,
ULONG *utf8_bytes_written,
@ -1870,6 +1875,13 @@ NTSTATUS NTAPI FsRtlRemoveDotsFromPath(PWSTR OriginalString,
NTSTATUS NTAPI FsRtlValidateReparsePointBuffer(ULONG BufferLength,
PREPARSE_DATA_BUFFER ReparseBuffer);
ULONG NTAPI KeQueryActiveProcessorCount(PKAFFINITY ActiveProcessors);
NTSTATUS NTAPI FsRtlGetEcpListFromIrp(IN PIRP Irp,
OUT PECP_LIST *EcpList);
NTSTATUS NTAPI FsRtlGetNextExtraCreateParameter(IN PECP_LIST EcpList,
IN PVOID CurrentEcpContext,
OUT LPGUID NextEcpType OPTIONAL,
OUT PVOID *NextEcpContext,
OUT PULONG NextEcpContextSize OPTIONAL);
#endif /* defined(__REACTOS__) && (NTDDI_VERSION < NTDDI_VISTA) */
#endif

View File

@ -2510,10 +2510,8 @@ static NTSTATUS file_create(PIRP Irp, _Requires_lock_held_(_Curr_->tree_lock) _R
UNICODE_STRING dsus, fpus, stream;
PIO_STACK_LOCATION IrpSp = IoGetCurrentIrpStackLocation(Irp);
POOL_TYPE pool_type = IrpSp->Flags & SL_OPEN_PAGING_FILE ? NonPagedPool : PagedPool;
#ifndef __REACTOS__
ECP_LIST* ecp_list;
ATOMIC_CREATE_ECP_CONTEXT* acec = NULL;
#endif
#ifdef DEBUG_FCB_REFCOUNTS
LONG oc;
#endif
@ -2526,7 +2524,6 @@ static NTSTATUS file_create(PIRP Irp, _Requires_lock_held_(_Curr_->tree_lock) _R
if (options & FILE_DELETE_ON_CLOSE && IrpSp->Parameters.Create.FileAttributes & FILE_ATTRIBUTE_READONLY)
return STATUS_CANNOT_DELETE;
#ifndef __REACTOS__
if (NT_SUCCESS(FsRtlGetEcpListFromIrp(Irp, &ecp_list)) && ecp_list) {
void* ctx = NULL;
GUID type;
@ -2543,7 +2540,6 @@ static NTSTATUS file_create(PIRP Irp, _Requires_lock_held_(_Curr_->tree_lock) _R
}
} while (NT_SUCCESS(Status));
}
#endif
dsus.Buffer = (WCHAR*)datasuf;
dsus.Length = dsus.MaximumLength = sizeof(datasuf) - sizeof(WCHAR);
@ -2720,7 +2716,6 @@ static NTSTATUS file_create(PIRP Irp, _Requires_lock_held_(_Curr_->tree_lock) _R
FileObject->SectionObjectPointer = &fileref->fcb->nonpaged->segment_object;
#ifndef __REACTOS__
// FIXME - ATOMIC_CREATE_ECP_IN_FLAG_BEST_EFFORT
if (acec && acec->InFlags & ATOMIC_CREATE_ECP_IN_FLAG_REPARSE_POINT_SPECIFIED) {
if (acec->ReparseBufferLength > sizeof(UINT32) && *(UINT32*)acec->ReparseBuffer == IO_REPARSE_TAG_SYMLINK) {
@ -2751,7 +2746,6 @@ static NTSTATUS file_create(PIRP Irp, _Requires_lock_held_(_Curr_->tree_lock) _R
acec->OutFlags |= ATOMIC_CREATE_ECP_OUT_FLAG_REPARSE_POINT_SET;
}
#endif
fileref->dc->type = fileref->fcb->type;