Skip to content

Commit

Permalink
Make FilterResult a scoped enum.
Browse files Browse the repository at this point in the history
  • Loading branch information
wilx committed Nov 8, 2024
1 parent 0e93761 commit 98834f1
Show file tree
Hide file tree
Showing 4 changed files with 87 additions and 68 deletions.
2 changes: 1 addition & 1 deletion include/log4cplus/spi/filter.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ namespace log4cplus {
namespace spi {


enum FilterResult { DENY, /**< The log event must be dropped immediately
enum class FilterResult { DENY, /**< The log event must be dropped immediately
* without consulting with the remaining
* filters, if any, in the chain. */
NEUTRAL, /**< This filter is neutral with respect to
Expand Down
2 changes: 1 addition & 1 deletion src/appender.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ Appender::syncDoAppend(const log4cplus::spi::InternalLoggingEvent& event)

// Evaluate filters attached to this appender.

if (checkFilter(filter.get(), event) == spi::DENY)
if (checkFilter(filter.get(), event) == spi::FilterResult::DENY)
return;

// Lock system wide lock.
Expand Down
Loading

0 comments on commit 98834f1

Please sign in to comment.