From 3706760c1b4d59fa5459bef1ecee04c3f28c244f Mon Sep 17 00:00:00 2001 From: progandy Date: Sun, 7 Oct 2012 22:10:00 +0200 Subject: [PATCH] force appname comparison when searching for duplicates. --- dunst.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dunst.c b/dunst.c index bf0e63e..fed36ba 100644 --- a/dunst.c +++ b/dunst.c @@ -923,7 +923,7 @@ int init_notification(notification * n, int id) /* check if n is a duplicate */ for (l_node * iter = notification_queue->head; iter; iter = iter->next) { notification *orig = (notification *) iter->data; - if (strcmp(orig->msg, n->msg) == 0) { + if (strcmp(orig->appname, n->appname) == 0 && strcmp(orig->msg, n->msg) == 0) { orig->dup_count++; free_notification(n); return orig->id; @@ -933,7 +933,7 @@ int init_notification(notification * n, int id) for (l_node * iter = displayed_notifications->head; iter; iter = iter->next) { notification *orig = (notification *) iter->data; - if (strcmp(orig->msg, n->msg) == 0) { + if (strcmp(orig->appname, n->appname) == 0 && strcmp(orig->msg, n->msg) == 0) { orig->dup_count++; orig->start = now; free_notification(n);