From 5054264d93bff2ad54d909d796e93f3081ee9703 Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Fri, 22 Mar 2024 22:12:55 -0400 Subject: Error messages --- src/template.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/template.c') diff --git a/src/template.c b/src/template.c index e046350..72c045b 100644 --- a/src/template.c +++ b/src/template.c @@ -30,7 +30,7 @@ void tpl_register(char *key, char **ptr) { struct tpl_item *item = NULL; item = calloc(1, sizeof(*item)); if (!item) { - perror("unable to register tpl_item"); + SYSERROR("unable to register tpl_item for %s", key); exit(1); } item->key = strdup(key); @@ -47,7 +47,7 @@ void tpl_free() { SYSERROR("freeing template item key: %s", item->key); guard_free(item->key); } - free(item); + SYSERROR("freeing template item: %p", item); item->ptr = NULL; } guard_free(item); -- cgit