2000-05-04 Kevin L. Mitchell <klmitch@mit.edu>
+ * ircd/channel.c: replace bogus assertions with returns, which is
+ logically correct; only wipe out limit/key if they were originally
+ set in the first place; remove user from channel when doing a
+ PARTALL; only send MODE +o for user CREATEing channel if user is
+ not MyUser--CREATE will only be used if the channel did not
+ originally exist, therefore we can assume no one local is on the
+ channel anyway, and we don't exactly need for the user to see an
+ explicit +o for themselves
+
* doc/readme.gline: describe the syntax of the GLINE command
* doc/readme.jupe: update to reflect a couple of changes to JUPE
#
# ChangeLog for ircu2.10.11
#
-# $Id: ChangeLog,v 1.135 2000-05-04 18:21:48 kev Exp $
+# $Id: ChangeLog,v 1.136 2000-05-04 18:54:31 kev Exp $
#
# Insert new changes at beginning of the change list.
#
return;
state->done |= DONE_LIMIT;
- assert(0 != state->mbuf);
+ if (!state->mbuf)
+ return;
modebuf_mode_uint(state->mbuf, state->dir | flag_p[0], t_limit);
return;
}
+ if (!state->mbuf)
+ return;
+
/* can't add a key if one is set, nor can one remove the wrong key */
if (!(state->flags & MODE_PARSE_FORCE))
if ((state->dir == MODE_ADD && *state->chptr->mode.key) ||
!ircd_strcmp(state->chptr->mode.key, t_str))
return; /* no key change */
- assert(0 != state->mbuf);
-
if (state->flags & MODE_PARSE_BOUNCE) {
if (*state->chptr->mode.key) /* reset old key */
modebuf_mode_string(state->mbuf, MODE_DEL | flag_p[0],
return;
}
- assert(0 != state->mbuf);
+ if (!state->mbuf)
+ return;
modebuf_mode(state->mbuf, state->dir | flag_p[0]);
return state.args_used; /* tell our parent how many args we gobbled */
if (state.flags & MODE_PARSE_WIPEOUT) {
- if (!(state.done & DONE_LIMIT)) /* remove the old limit */
+ if (state.chptr->mode.limit && !(state.done & DONE_LIMIT))
modebuf_mode_uint(state.mbuf, MODE_DEL | MODE_LIMIT,
state.chptr->mode.limit);
- if (!(state.done & DONE_KEY)) /* remove the old key */
+ if (*state.chptr->mode.key && !(state.done & DONE_KEY))
modebuf_mode_string(state.mbuf, MODE_DEL | MODE_KEY,
state.chptr->mode.key, 0);
}
* when we gang all the channel parts together. Note that this is
* exactly the same logic, albeit somewhat more concise, as was in
* the original m_part.c */
+
+ if (jbuf->jb_type == JOINBUF_TYPE_PARTALL) /* got to remove user here */
+ remove_user_from_channel(jbuf->jb_source, chan);
} else {
/* Add user to channel */
add_user_to_channel(chan, jbuf->jb_source, flags);
sendcmdto_channel_butserv(jbuf->jb_source, CMD_JOIN, chan, ":%H", chan);
/* send an op, too, if needed */
- if (jbuf->jb_type == JOINBUF_TYPE_CREATE &&
+ if (!MyUser(jbuf->jb_source) && jbuf->jb_type == JOINBUF_TYPE_CREATE &&
!IsModelessChannel(chan->chname))
sendcmdto_channel_butserv(jbuf->jb_source, CMD_MODE, chan, "%H +o %C",
chan, jbuf->jb_source);