aboutsummaryrefslogtreecommitdiff
path: root/notify.c
diff options
context:
space:
mode:
authorCraig Barnes <craigbarnes@protonmail.com>2024-08-03 07:12:13 +0000
committerCraig Barnes <craigbarnes@protonmail.com>2024-08-03 07:51:06 +0000
commitf87c9bb9f70f1a6c8c7081c762c15ba7eaaf971e (patch)
treeaa30277b7b180ec4af22163aebf63686fc93e0be /notify.c
parentchangelog: add new 'unreleased' section (diff)
xmalloc: remove delim param from xstrjoin() and add separate xstrjoin3()
This avoids the need for an unused third argument for most xstrjoin() calls and replaces the cases where it's needed with a more flexible function. Code generation is the same in both cases, when there are 2 string params and a compile-time known delimiter. This commit also converts 4 uses of xasprintf() to use xstrjoin*(). See also: https://godbolt.org/z/xsjrhv9b6
Diffstat (limited to 'notify.c')
-rw-r--r--notify.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/notify.c b/notify.c
index 9d2d3c71..15139c40 100644
--- a/notify.c
+++ b/notify.c
@@ -77,7 +77,7 @@ write_icon_file(const void *data, size_t data_sz, int *fd, char **filename,
LOG_DBG("wrote icon data to %s", name);
*filename = xstrdup(name);
- *symbolic_name = xasprintf("file://%s", *filename);
+ *symbolic_name = xstrjoin("file://", *filename);
return true;
}