heap_helper.h 823 B

123456789101112131415161718192021222324
  1. // Copyright 2017 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #ifndef SANDBOX_WIN_SRC_HEAP_HELPER_H_
  5. #define SANDBOX_WIN_SRC_HEAP_HELPER_H_
  6. #include "base/win/windows_types.h"
  7. namespace sandbox {
  8. // These helper functions are not expected to be used generally, but are exposed
  9. // only to allow direct testing of this functionality.
  10. // Return the flags for this heap handle. Limited verification of the handle is
  11. // performed. No verification of the flags is performed.
  12. bool HeapFlags(HANDLE handle, DWORD* flags);
  13. // Return the handle to the CSR Port Heap, return nullptr if none or more than
  14. // one candidate was found.
  15. HANDLE FindCsrPortHeap();
  16. } // namespace sandbox
  17. #endif // SANDBOX_WIN_SRC_HEAP_HELPER_H_