AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Informational 15 Bitcoin

scripted-diff: logging: Drop LogAcceptCategory

Public commit record

What the developer wrote

Authored by Anthony Towns

78/100 · Adequate
scripted-diff: logging: Drop LogAcceptCategory

-BEGIN VERIFY SCRIPT-
sed -i 's/LogAcceptCategory(\(.*\), [a-zA-Z:]*::Level::Debug)/util::log::ShouldDebugLog(\1)/g' $(git grep -l LogAcceptCategory -- '*.cpp')
sed -i 's/LogAcceptCategory(\(.*\), [a-zA-Z:]*::Level::Trace)/util::log::ShouldTraceLog(\1)/g' $(git grep -l LogAcceptCategory -- '*.cpp')
sed -i '/Return true if log accepts specified category/,/^$/d' src/logging.h
-END VERIFY SCRIPT-
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
The short version

What changed, and why it matters

This is a routine internal code cleanup in Bitcoin Core. It replaces an older logging helper function called LogAcceptCategory with newer, more specific helper functions (ShouldDebugLog and ShouldTraceLog). The behavior of the program is intended to remain exactly the same; only the names of the functions used to decide what to log have changed. There is no indication this fixes or introduces a security vulnerability.

Recommended action

No security action required. Treat as normal refactoring. If reviewing, verify that util::log::ShouldDebugLog and util::log::ShouldTraceLog are exact behavioral replacements for the prior LogAcceptCategory calls and that no call sites were missed by the scripted diff.

Security signals we found

No strong security signals were identified.

Risk score

Why this scored 15/100

Our methodology →
Potential impact 0/30
Exploitability 0/25
Stealth signal 0/15
Affected reach 0/15
Confidence 10/10
Evidence quality 5/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.