Avoid copying message to match if no ignores are set

master
C. McEnroe 2020-07-06 22:51:15 -04:00
parent cb84983dd1
commit d74ec7e0f3
1 changed files with 1 additions and 0 deletions

View File

@ -72,6 +72,7 @@ bool ignoreRemove(const char *pattern) {
}
enum Heat ignoreCheck(enum Heat heat, uint id, const struct Message *msg) {
if (!ignore.len) return heat;
char match[512];
snprintf(
match, sizeof(match), "%s!%s@%s %s %s %s",