X-Git-Url: https://git.octo.it/?p=collectd.git;a=blobdiff_plain;f=src%2Fnotify_desktop.c;h=e430b681c398257e350dab8efb01769d02f49520;hp=e391cf275c04410ac76b67bbf6c896977f0fc74f;hb=54619dc85fd308b21ed09a0271e5c7383c7921b9;hpb=3d082a905619c19ca5b7183bb95a30d4d9529c4d diff --git a/src/notify_desktop.c b/src/notify_desktop.c index e391cf27..e430b681 100644 --- a/src/notify_desktop.c +++ b/src/notify_desktop.c @@ -30,8 +30,8 @@ #include "collectd.h" -#include "common.h" #include "plugin.h" +#include "utils/common/common.h" #include #include @@ -93,16 +93,16 @@ static int c_notify(const notification_t *n, timeout = fail_timeout; } - snprintf(summary, sizeof(summary), "collectd %s notification", - (NOTIF_FAILURE == n->severity) - ? "FAILURE" - : (NOTIF_WARNING == n->severity) - ? "WARNING" - : (NOTIF_OKAY == n->severity) ? "OKAY" : "UNKNOWN"); + ssnprintf(summary, sizeof(summary), "collectd %s notification", + (NOTIF_FAILURE == n->severity) + ? "FAILURE" + : (NOTIF_WARNING == n->severity) + ? "WARNING" + : (NOTIF_OKAY == n->severity) ? "OKAY" : "UNKNOWN"); notification = notify_notification_new(summary, n->message, NULL #if NOTIFY_CHECK_VERSION(0, 7, 0) - ); + ); #else , NULL);