Skip to content

Commit 423029b

Browse files
committed
WebCore scope for logging
1 parent 9a1bb05 commit 423029b

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

Source/WebCore/platform/qt/QtDiskCacheDelegate.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
#include <wtf/text/MakeString.h>
3838
#include <wtf/HexNumber.h>
3939
#include "Logging.h"
40+
#include "LogInitialization.h"
4041

4142
namespace WebCore {
4243

@@ -52,8 +53,10 @@ QtDiskCacheDelegate::QtDiskCacheDelegate(const QString& cachePath, size_t maxSiz
5253
});
5354

5455
// Initialize eagerly if logging is enabled to show startup message
55-
if (LogBytecodeCache.state != WTFLogChannelState::Off)
56-
ensureInitialized();
56+
if (WTFLogChannel* logChannel = getLogChannel("BytecodeCache"_s)) {
57+
if(logChannel->state != WTFLogChannelState::Off)
58+
ensureInitialized();
59+
}
5760
}
5861

5962
void QtDiskCacheDelegate::ensureInitialized()

0 commit comments

Comments
 (0)