-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Improve validation for StringMatchFilter for null/empty text #3153 #3158
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Thank you for your contribution. Can you add some unit tests to the PR? |
Hi @ppkarwasz I looked to see if I could extend an existing test for StringMatchFilter but there were no existing unit-tests. |
Yes, it happens. 😉 Can you create a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
This should fix a potential NPE in StringMatchFilter if the 'text' field is not set or set to null/empty string. #3153
Checklist
2.x
branch if you are targeting Log4j 2; usemain
otherwise./mvnw verify
succeeds (if it fails due to code formatting issues reported by Spotless, simply run./mvnw spotless:apply
and retry)src/changelog/.2.x.x
directory