From 9f69e7b26c4e62265098651bb189f36b464a690d Mon Sep 17 00:00:00 2001 From: klzgrad Date: Mon, 7 Oct 2024 15:57:25 +0800 Subject: [PATCH] base, net: Fix disabling tracing --- src/base/trace_event/trace_event_stub.cc | 4 ++++ src/net/base/trace_event_stub.h | 6 +++--- src/net/base/tracing.h | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/base/trace_event/trace_event_stub.cc b/src/base/trace_event/trace_event_stub.cc index 8c40ae3463..ecadae09cf 100644 --- a/src/base/trace_event/trace_event_stub.cc +++ b/src/base/trace_event/trace_event_stub.cc @@ -6,6 +6,7 @@ #include +#include "base/trace_event/memory_usage_estimator.h" #include "base/trace_event/trace_event_stub.h" namespace base { @@ -20,6 +21,9 @@ MemoryDumpProvider::~MemoryDumpProvider() = default; // static constexpr const char* const MemoryDumpManager::kTraceCategory; +template size_t EstimateMemoryUsage(const std::string&); +template size_t EstimateMemoryUsage(const std::u16string&); + } // namespace trace_event } // namespace base diff --git a/src/net/base/trace_event_stub.h b/src/net/base/trace_event_stub.h index ec3f0a9996..ef08fa533d 100644 --- a/src/net/base/trace_event_stub.h +++ b/src/net/base/trace_event_stub.h @@ -12,9 +12,9 @@ #ifndef NET_BASE_TRACE_EVENT_STUB_H_ #define NET_BASE_TRACE_EVENT_STUB_H_ -#import "base/base_export.h" -#import "base/memory/weak_ptr.h" -#import "base/trace_event/trace_event_stub.h" +#include "base/base_export.h" +#include "base/memory/weak_ptr.h" +#include "base/trace_event/trace_event_stub.h" namespace base::trace_event { diff --git a/src/net/base/tracing.h b/src/net/base/tracing.h index 31c90ac1b9..8fb0675877 100644 --- a/src/net/base/tracing.h +++ b/src/net/base/tracing.h @@ -8,7 +8,7 @@ #include "build/build_config.h" #include "net/base/cronet_buildflags.h" -#if BUILDFLAG(CRONET_BUILD) && !BUILDFLAG(IS_APPLE) +#if BUILDFLAG(CRONET_BUILD) #include "net/base/trace_event_stub.h" // IWYU pragma: export #endif // BUILDFLAG(CRONET_BUILD) && !BUILDFLAG(IS_APPLE)