]>
jfr.im git - irc/quakenet/newserv.git/blob - newsearch/ns-exists.c
10 void *exists_exe(searchCtx
*ctx
, struct searchNode
*thenode
, void *theinput
);
11 void exists_free(searchCtx
*ctx
, struct searchNode
*thenode
);
13 struct searchNode
*exists_parse(searchCtx
*ctx
, int argc
, char **argv
) {
14 struct searchNode
*thenode
;
16 if (!(thenode
=(struct searchNode
*)malloc(sizeof (struct searchNode
)))) {
17 parseError
= "malloc: could not allocate memory for this search.";
21 thenode
->returntype
= RETURNTYPE_BOOL
;
22 thenode
->localdata
= NULL
;
23 thenode
->exe
= exists_exe
;
24 thenode
->free
= exists_free
;
29 void *exists_exe(searchCtx
*ctx
, struct searchNode
*thenode
, void *theinput
) {
30 chanindex
*cip
= (chanindex
*)theinput
;
32 if (cip
->channel
== NULL
)
38 void exists_free(searchCtx
*ctx
, struct searchNode
*thenode
) {