don't try to replace NULL icon

This commit is contained in:
Sascha Kruse 2012-12-13 22:49:11 +01:00
parent 6de6ef0619
commit 43b2b3bb1d

View File

@ -833,8 +833,10 @@ int init_notification(notification * n, int id)
n->msg = string_replace("%a", n->appname, strdup(n->format)); n->msg = string_replace("%a", n->appname, strdup(n->format));
n->msg = string_replace("%s", n->summary, n->msg); n->msg = string_replace("%s", n->summary, n->msg);
n->msg = string_replace("%i", n->icon, n->msg); if (n->icon) {
n->msg = string_replace("%I", basename(n->icon), n->msg); n->msg = string_replace("%I", basename(n->icon), n->msg);
n->msg = string_replace("%i", n->icon, n->msg);
}
n->msg = string_replace("%b", n->body, n->msg); n->msg = string_replace("%b", n->body, n->msg);
if (n->progress) { if (n->progress) {
char pg[10]; char pg[10];