From 011989fbb773a1568be6d8609fb821ea8e62fb0f Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Tue, 23 Jun 2015 12:22:53 +0200 Subject: introduce config.h --- journal-notify.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'journal-notify.c') diff --git a/journal-notify.c b/journal-notify.c index 2d425be..024a7d5 100644 --- a/journal-notify.c +++ b/journal-notify.c @@ -303,10 +303,10 @@ int main(int argc, char **argv) { if (have_regex == 0 || regexec(®ex, message, 0, NULL, 0) == 0) { /* throttling */ notification_count++; - if (notification_count >= 6) { + if (notification_count >= THROTTLE_THRESHOLD) { if (verbose) - fprintf(stderr, "Already showed %u notifications, throttling!\n", notification_count - 1); - if (executeonly == 0 && notification_count == 6) { + fprintf(stderr, "This is the %uth notification, throttling!\n", notification_count); + if (executeonly == 0 && notification_count == THROTTLE_THRESHOLD) { if ((rc = notify(program, "Throttling notification! View your journal for complete log.", 0, "dialog-warning", timeout)) > 0) { fprintf(stderr, "Failed to show notification.\n"); } -- cgit v1.2.3-54-g00ecf