- /*
- * Special Case 3: User isn't on this channel, show all visible users, in
- * non secret channels.
- */
- do_names(sptr, chptr, NAMES_VIS);
- }
- } else { /* Channel doesn't exist. */
- send_reply(sptr, RPL_ENDOFNAMES, para);
- }
- return 1;
-}
-
-
-#if 0
-/*
- * m_names - Added by Jto 27 Apr 1989
- *
- * parv[0] = sender prefix
- * parv[1] = channel
- */
-int m_names(struct Client *cptr, struct Client *sptr, int parc, char *parv[])
-{
- struct Channel *chptr;
- struct Client *c2ptr;
- struct Membership* member;
- struct Channel *ch2ptr = 0;
- int idx, flag, len, mlen;
- char *s, *para = parc > 1 ? parv[1] : 0;
- char buf[BUFSIZE];
-
- if (parc > 2 && hunt_server(1, cptr, sptr, "%s%s " TOK_NAMES " %s %s", 2, parc, parv)) /* XXX DEAD */
- return 0;
-
- mlen = strlen(me.name) + 10 + strlen(sptr->name);
-
- if (!EmptyString(para))
- {
- s = strchr(para, ',');
- if (s)
- {
- parv[1] = ++s;
- m_names(cptr, sptr, parc, parv);
- }
- clean_channelname(para);
- ch2ptr = FindChannel(para);
- }
-
- /*
- * First, do all visible channels (public and the one user self is)
- */
-
- for (chptr = GlobalChannelList; chptr; chptr = chptr->next)
- {
- if ((chptr != ch2ptr) && !EmptyString(para))
- continue; /* -- wanted a specific channel */
- if (!MyConnect(sptr) && EmptyString(para))
- continue;
-#ifndef GODMODE
- if (!ShowChannel(sptr, chptr))
- continue; /* -- users on this are not listed */
-#endif
-
- /* Find users on same channel (defined by chptr) */
-
- strcpy(buf, "* ");
- len = strlen(chptr->chname);
- strcpy(buf + 2, chptr->chname);
- strcpy(buf + 2 + len, " :");
-
- if (PubChannel(chptr))
- *buf = '=';
- else if (SecretChannel(chptr))
- *buf = '@';
- idx = len + 4;
- flag = 1;
- for (member = chptr->members; member; member = member->next_member)
- {
- c2ptr = member->user;
-#ifndef GODMODE
- if (sptr != c2ptr && IsInvisible(c2ptr) && !find_channel_member(sptr, chptr))
- continue;
-#endif
- if (IsZombie(member))