From 44bcab7c9cc9edf0894ca710da34beca63517b03 Mon Sep 17 00:00:00 2001 From: Luke Bratch Date: Fri, 2 Sep 2022 17:17:41 +0100 Subject: Improve comment/debug clarity. --- functions.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'functions.c') diff --git a/functions.c b/functions.c index 7184bfa..6d0e8a1 100644 --- a/functions.c +++ b/functions.c @@ -318,18 +318,18 @@ void updatenickuserhost(char *nickuserhost, char *nick) { // Find the bang for (size_t i = 0; i < strlen(nickuserhost); i++) { if (nickuserhost[i] == '!') { - debugprint(DEBUG_FULL, "Found bang at position %ld!\n", i); + debugprint(DEBUG_FULL, "updatenickuserhost(): found bang at position %ld!\n", i); bangpos = i; break; } } if (bangpos == -1) { - debugprint(DEBUG_FULL, "No bang found in existing nickuserhost, quitting!\n"); + debugprint(DEBUG_FULL, "updatenickuserhost(): no bang found in existing nickuserhost, returning!\n"); return; } - // Make a new string combining the nick nick and the old nickuserhost + the offset of the bang + // Make a new string combining the new nick and the old nickuserhost + the offset of the bang char newstr[MAXDATASIZE]; snprintf(newstr, MAXDATASIZE, "%s%s", nick, nickuserhost + bangpos); newstr[strlen(nickuserhost) - bangpos + strlen(nick)] = '\0'; -- cgit v1.2.3