* $Id: m_who.c 3350 2007-04-02 22:03:08Z jilles $
*/
#include "stdinc.h"
-#include "tools.h"
#include "common.h"
#include "client.h"
#include "channel.h"
#include "irc_string.h"
#include "sprintf_irc.h"
#include "s_conf.h"
-#include "s_log.h"
+#include "logger.h"
#include "msg.h"
#include "parse.h"
#include "modules.h"
struct Client *target_p;
struct membership *msptr;
char *mask;
- dlink_node *lp;
+ rb_dlink_node *lp;
struct Channel *chptr = NULL;
int server_oper = parc > 2 ? (*parv[2] == 'o') : 0; /* Show OPERS only */
int member;
int isinvis = 0;
isinvis = IsInvisible(target_p);
- DLINK_FOREACH(lp, target_p->user->channel.head)
+ RB_DLINK_FOREACH(lp, target_p->user->channel.head)
{
msptr = lp->data;
chptr = msptr->chptr;
/* it has to be a global who at this point, limit it */
if(!IsOper(source_p))
{
- if((last_used + ConfigFileEntry.pace_wait) > CurrentTime)
+ if((last_used + ConfigFileEntry.pace_wait) > rb_current_time())
{
sendto_one(source_p, form_str(RPL_LOAD2HI),
me.name, source_p->name, "WHO");
return 0;
}
else
- last_used = CurrentTime;
+ last_used = rb_current_time();
}
/* Note: operspy_dont_care_user_info does not apply to
{
struct membership *msptr;
struct Client *target_p;
- dlink_node *ptr;
+ rb_dlink_node *ptr;
- DLINK_FOREACH(ptr, chptr->members.head)
+ RB_DLINK_FOREACH(ptr, chptr->members.head)
{
msptr = ptr->data;
target_p = msptr->client_p;
{
struct membership *msptr;
struct Client *target_p;
- dlink_node *lp, *ptr;
+ rb_dlink_node *lp, *ptr;
int maxmatches = 500;
/* first, list all matching INvisible clients on common channels
*/
if(!operspy)
{
- DLINK_FOREACH(lp, source_p->user->channel.head)
+ RB_DLINK_FOREACH(lp, source_p->user->channel.head)
{
msptr = lp->data;
who_common_channel(source_p, msptr->chptr, mask, server_oper, &maxmatches);
* if this is an operspy who, list all matching clients, no need
* to clear marks
*/
- DLINK_FOREACH(ptr, global_client_list.head)
+ RB_DLINK_FOREACH(ptr, global_client_list.head)
{
target_p = ptr->data;
if(!IsPerson(target_p))
{
struct Client *target_p;
struct membership *msptr;
- dlink_node *ptr;
+ rb_dlink_node *ptr;
int combine = IsCapable(source_p, CLICAP_MULTI_PREFIX);
- DLINK_FOREACH(ptr, chptr->members.head)
+ RB_DLINK_FOREACH(ptr, chptr->members.head)
{
msptr = ptr->data;
target_p = msptr->client_p;
{
char status[5];
- ircsprintf(status, "%c%s%s",
+ rb_sprintf(status, "%c%s%s",
target_p->user->away ? 'G' : 'H', IsOper(target_p) ? "*" : "", op_flags);
sendto_one(source_p, form_str(RPL_WHOREPLY), me.name, source_p->name,