From 591b6cd4c1402e89702621341c2868d5eaaf7154 Mon Sep 17 00:00:00 2001 From: c9s Date: Fri, 23 May 2014 23:00:49 +0800 Subject: [PATCH] when matching pcre do not switch check rc --- src/node.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/node.c b/src/node.c index 3e6f474..06575a3 100644 --- a/src/node.c +++ b/src/node.c @@ -313,8 +313,10 @@ node * r3_tree_matchl(const node * n, char * path, int path_len, match_entry * e ov, /* output vector for substring information */ ov_cnt); /* number of elements in the output vector */ - // info("rc: %d\n", rc ); + // does not match all edges, return NULL; if (rc < 0) { +#ifdef DEBUG + printf("pcre rc: %d\n", rc ); switch(rc) { case PCRE_ERROR_NOMATCH: @@ -326,7 +328,7 @@ node * r3_tree_matchl(const node * n, char * path, int path_len, match_entry * e printf("pcre matching error '%d' '%s' on pattern '%s'\n", rc, path, n->combined_pattern); break; } - // does not match all edges, return NULL; +#endif return NULL; }