Log message:
Added 'End of Names' when joining channel. thanks to hektik for pointing
this out.
Testing needed:
* Make sure it displays End Of Names when it should
* Make sure it doesn't display End Of Names when it shouldn't
git-svn-id: file:///home/klmitch/undernet-ircu/undernet-ircu-svn/ircu2/trunk@320
c9e4aea6-c8fd-4c43-8297-
357d70d61c8c
+2000-12-04 Isomer <isomer@coders.net>
+ * ircd/m_names.c: Add NAMES_EON to do_names to say add a
+ 'end_of_names' reply when done.
+ * ircd/m_join.c: use NAMES_EON as mentioned above
+
2000-12-01 net <simms@LUCIDA.QC.CA>
* ircd/motd.c: add a freelist for struct Motds
#define NAMES_ALL 1 /* List all users in channel */
#define NAMES_VIS 2 /* List only visible users in non-secret channels */
+#define NAMES_EON 4 /* Add an 'End Of Names' reply to the end */
void do_names(struct Client* sptr, struct Channel* chptr, int filter);
chptr->topic_time);
}
- do_names(sptr, chptr, NAMES_ALL); /* send /names list */
+ do_names(sptr, chptr, NAMES_ALL|NAMES_EON); /* send /names list */
}
joinbuf_flush(&join); /* must be first, if there's a JOIN 0 */
*
* NAMES_ALL - Lists all users on channel.
* NAMES_VIS - Only list visible (-i) users. --Gte (04/06/2000).
+ * NAMES_EON - When OR'd with the other two, adds an 'End of Names' numeric
+ * used by m_join
*
*/
char buf[BUFSIZE];
struct Client *c2ptr;
struct Membership* member;
+
+ assert(chptr);
+ assert(sptr);
+ assert((filter&NAMES_ALL) != (filter&NAMES_VIS));
/* Tag Pub/Secret channels accordingly. */
{
c2ptr = member->user;
- if ((filter == NAMES_VIS) && IsInvisible(c2ptr))
+ if (((filter&NAMES_VIS)!=0) && IsInvisible(c2ptr))
continue;
if (IsZombie(member) && member->user != sptr)
}
if (flag)
send_reply(sptr, RPL_NAMREPLY, buf);
+ if (filter&NAMES_EON)
+ send_reply(sptr, RPL_ENDOFNAMES, chptr->chname);
}
/*