From 5f4429bf7b3454baeb5e33c72c1c9889942b1f0c Mon Sep 17 00:00:00 2001 From: Kevin Easton Date: Thu, 25 Jun 2015 11:45:09 +1000 Subject: [PATCH] Removed unused variable from output_reject_ctcp() Also remove unnecessary tests for stuff and stuff->user - these are always non-null when the callback is called. --- source/dcc.c | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/source/dcc.c b/source/dcc.c index efce54c..e34456a 100644 --- a/source/dcc.c +++ b/source/dcc.c @@ -3045,21 +3045,19 @@ int dcc_exempt_save(FILE *fptr) */ static void output_reject_ctcp (UserhostItem *stuff, char *nick, char *args) { - char *nickname_requested; - char *nickname_recieved; - char *type; - char *description; - if (!stuff || !stuff->user || !strcmp(stuff->user, "")) - { + char *nickname_recieved; + char *type; + char *description; + + if (!strcmp(stuff->user, "")) return; - } /* * XXX This is, of course, a monsterous hack. */ - nickname_requested = next_arg(args, &args); - type = next_arg(args, &args); - description = next_arg(args, &args); - nickname_recieved = stuff->nick; + next_arg(args, &args); + type = next_arg(args, &args); + description = next_arg(args, &args); + nickname_recieved = stuff->nick; if (nickname_recieved && *nickname_recieved) send_ctcp(CTCP_NOTICE, nickname_recieved, CTCP_DCC,