void not_free(searchCtx *ctx, struct searchNode *thenode);
void *not_exe(searchCtx *ctx, struct searchNode *thenode, void *theinput);
-struct searchNode *not_parse(searchCtx *ctx, int type, int argc, char **argv) {
+struct searchNode *not_parse(searchCtx *ctx, int argc, char **argv) {
searchNode *thenode, *subnode;
if (argc!=1) {
thenode->exe = not_exe;
thenode->free = not_free;
- subnode=ctx->parser(ctx, type, argv[0]); /* Propogate the search type */
+ subnode=ctx->parser(ctx, argv[0]); /* Propogate the search type */
if (!subnode) {
free(thenode);
/* Our subnode needs to return a BOOL */
subnode=coerceNode(ctx, subnode, RETURNTYPE_BOOL);
-
+ if(!subnode) {
+ free(thenode);
+ return NULL;
+ }
+
thenode->localdata=(void *)subnode;
return thenode;