From 89a5417a11e13c774018d4120772b2ebe143252f Mon Sep 17 00:00:00 2001 From: Kevin Easton Date: Mon, 2 Jan 2017 15:16:13 +1100 Subject: [PATCH] Use %d sprintf() format for 'int' arguments rather than %u --- source/hook.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/source/hook.c b/source/hook.c index 96d7313..0177164 100644 --- a/source/hook.c +++ b/source/hook.c @@ -379,7 +379,7 @@ static void add_numeric_hook (int numeric, char *nick, char *stuff, Noise noisy, { entry = (NumericList *) new_malloc(sizeof(NumericList)); entry->numeric = numeric; - sprintf(entry->name, "%3.3u", numeric); + sprintf(entry->name, "%3.3d", numeric); entry->next = NULL; entry->list = NULL; add_numeric_list(entry); @@ -416,7 +416,7 @@ static void add_numeric_dll_hook (int numeric, Noise noise, int serial, char *ni { entry = (NumericList *) new_malloc(sizeof(NumericList)); entry->numeric = numeric; - sprintf(entry->name, "%3.3u", numeric); + sprintf(entry->name, "%3.3d", numeric); entry->next = NULL; entry->list = NULL; add_numeric_list(entry); @@ -768,7 +768,7 @@ static int show_numeric_list (int numeric) if (numeric) { - sprintf(buf, "%3.3u", numeric); + sprintf(buf, "%3.3d", numeric); if ((tmp = find_numeric_list(numeric))) { for (list = tmp->list; list; list = list->next, cnt++) @@ -1642,7 +1642,7 @@ void do_stack_on (int type, char *args) nptr->list = p->list; nptr->next = NULL; nptr->numeric = -which; - sprintf(nptr->name, "%3.3u", -which); + sprintf(nptr->name, "%3.3d", -which); add_numeric_list(nptr); } }