X-Git-Url: https://jfr.im/git/irc/quakenet/newserv.git/blobdiff_plain/ab721714c30f4df9fabf5fbd5a90f074f53d82e2..8c684fca9c7dbb4a2601628c744be9236ee68641:/chanserv/chancmds/op.c diff --git a/chanserv/chancmds/op.c b/chanserv/chancmds/op.c index 0bf6d45e..b4a9cc37 100644 --- a/chanserv/chancmds/op.c +++ b/chanserv/chancmds/op.c @@ -81,6 +81,12 @@ int csc_doop(void *source, int cargc, char **cargv) { return CMD_ERROR; rcp=cip->exts[chanservext]; + + /* If the channel doesn't currently exist, forget it. */ + if (!cip->channel) { + chanservstdmessage(sender, QM_EMPTYCHAN, cip->name->content); + return CMD_ERROR; + } if (cargc==1) { /* Only one arg: "op me" */ @@ -137,7 +143,7 @@ int csc_doop(void *source, int cargc, char **cargv) { } if (donotice && bufpos) { - sendopnoticetochannel(chanservnick, cip->channel, "%s opped %s", sender, buf); + sendopnoticetochannel(chanservnick, cip->channel, "%s opped %s", sender->nick, buf); } localsetmodeflush(&changes, 1);