Minor cleanup for error_not_opped().

git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@135 13b04d17-f746-0410-82c6-800466cd88b0
This commit is contained in:
Kevin Easton
2011-08-30 14:52:56 +00:00
parent c89a718fa1
commit 83ac47c4f5
2 changed files with 4 additions and 4 deletions

View File

@@ -1727,9 +1727,11 @@ int are_you_opped(char *channel)
return is_chanop(channel, get_server_nickname(from_server));
}
void error_not_opped(char *channel)
void error_not_opped(const char *channel)
{
set_display_target(channel, LOG_CRAP);
say("You're not opped on %s", channel);
reset_display_target();
}
int freadln(FILE *stream, char *lin)
@@ -4861,9 +4863,7 @@ ChannelList *chan = NULL;
}
if (need_op == NEED_OP && chan && !chan->have_op && !chan->hop)
{
set_display_target(chan->channel, LOG_CRAP);
error_not_opped(chan->channel);
reset_display_target();
return NULL;
}
return chan;