Home | Info | Community | Development | myReactOS | Contact Us
Definition at line 322 of file heapdbg.c.
Referenced by RtlGetUserInfoHeap().
{ PHEAP Heap = (PHEAP)HeapHandle; BOOLEAN HeapLocked = FALSE; PHEAP_ENTRY HeapEntry; BOOLEAN Result = FALSE; if (Heap->ForceFlags & HEAP_FLAG_PAGE_ALLOCS) return RtlpPageHeapGetUserInfo(HeapHandle, Flags, BaseAddress, UserValue, UserFlags); if (Heap->Signature != HEAP_SIGNATURE) { DPRINT1("HEAP: Invalid heap %p signature 0x%x\n", Heap, Heap->Signature); return FALSE; } /* Add skip validation flag */ Flags |= Heap->ForceFlags | HEAP_SKIP_VALIDATION_CHECKS; /* Lock the heap ourselves */ if (!(Flags & HEAP_NO_SERIALIZE)) { RtlEnterHeapLock(Heap->LockVariable, TRUE); HeapLocked = TRUE; /* Add no serialize flag so that the main routine won't try to acquire the lock again */ Flags |= HEAP_NO_SERIALIZE; } /* Validate the heap if necessary */ RtlpValidateHeap(Heap, FALSE); /* Get the existing heap entry */ HeapEntry = (PHEAP_ENTRY)BaseAddress - 1; /* Validate it */ if (RtlpValidateHeapEntry(Heap, HeapEntry)) { /* If it succeeded - call the main routine */ Result = RtlGetUserInfoHeap(HeapHandle, Flags, BaseAddress, UserValue, UserFlags); } /* Release the lock */ if (HeapLocked) RtlLeaveHeapLock(Heap->LockVariable); return Result; }