X-Git-Url: https://jfr.im/git/irc/quakenet/newserv.git/blobdiff_plain/1f980bdf5093d59a9d2664b79527c494a03c4347..f33f3f52f58acdd2b9b6796713ac8f24d9881545:/newsearch/ns-notice.c diff --git a/newsearch/ns-notice.c b/newsearch/ns-notice.c index 3c0861f8..5adeeb77 100644 --- a/newsearch/ns-notice.c +++ b/newsearch/ns-notice.c @@ -22,11 +22,10 @@ void notice_free(searchCtx *ctx, struct searchNode *thenode); struct notice_localdata { unsigned int marker; int count; - int type; char message[NSMAX_NOTICE_LEN]; }; -struct searchNode *notice_parse(searchCtx *ctx, int type, int argc, char **argv) { +struct searchNode *notice_parse(searchCtx *ctx, int argc, char **argv) { struct notice_localdata *localdata; struct searchNode *thenode; int len; @@ -36,8 +35,7 @@ struct searchNode *notice_parse(searchCtx *ctx, int type, int argc, char **argv) return NULL; } localdata->count = 0; - localdata->type = type; - if (type == SEARCHTYPE_CHANNEL) + if (ctx->type == SEARCHTYPE_CHANNEL) localdata->marker = nextchanmarker(); else localdata->marker = nextnickmarker(); @@ -82,7 +80,7 @@ void *notice_exe(searchCtx *ctx, struct searchNode *thenode, void *theinput) { localdata = thenode->localdata; - if (localdata->type == SEARCHTYPE_CHANNEL) { + if (ctx->type == SEARCHTYPE_CHANNEL) { cip = (chanindex *)theinput; cip->marker = localdata->marker; localdata->count += cip->channel->users->totalusers; @@ -105,7 +103,7 @@ void notice_free(searchCtx *ctx, struct searchNode *thenode) { localdata = thenode->localdata; - if (localdata->type == SEARCHTYPE_CHANNEL) { + if (ctx->type == SEARCHTYPE_CHANNEL) { nickmarker=nextnickmarker(); for (i=0;i