Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
allocator_shim_config.cpp
Go to the documentation of this file.
1
// Copyright 2023 The PDFium Authors
2
// Use of this source code is governed by a BSD-style license that can be
3
// found in the LICENSE file.
4
5
#
include
"testing/allocator_shim_config.h"
6
7
#
include
"partition_alloc/dangling_raw_ptr_checks.h"
8
#
include
"partition_alloc/partition_alloc_buildflags.h"
9
#
include
"partition_alloc/shim/allocator_shim_default_dispatch_to_partition_alloc.h"
10
#
include
"third_party/base/check.h"
11
12
namespace
pdfium {
13
14
void
ConfigurePartitionAllocShimPartitionForTest
() {
15
#
if
BUILDFLAG
(
USE_PARTITION_ALLOC_AS_MALLOC
)
16
#
if
BUILDFLAG
(
ENABLE_BACKUP_REF_PTR_SUPPORT
)
17
#
if
BUILDFLAG
(
ENABLE_DANGLING_RAW_PTR_CHECKS
)
18
partition_alloc::SetDanglingRawPtrDetectedFn([](uintptr_t) { CHECK(0); });
19
#
endif
// BUILDFLAG(ENABLE_DANGLING_RAW_PTR_CHECKS)
20
allocator_shim::ConfigurePartitionsForTesting();
21
#
endif
// BUILDFLAG(ENABLE_BACKUP_REF_PTR_SUPPORT)
22
#
endif
// BUILDFLAG(USE_PARTITION_ALLOC_AS_MALLOC)
23
}
24
25
}
// namespace pdfium
pdfium::ConfigurePartitionAllocShimPartitionForTest
void ConfigurePartitionAllocShimPartitionForTest()
Definition
allocator_shim_config.cpp:14
qtwebengine
src
3rdparty
chromium
third_party
pdfium
testing
allocator_shim_config.cpp
Generated on Thu Nov 14 2024 01:03:34 for Qt by
1.12.0