From: K.Kosako Date: Tue, 6 Jun 2017 04:23:07 +0000 (+0900) Subject: define SET_ENCLOSE_RECURSION() X-Git-Tag: v6.4.0~1^2~148 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b2f7c85d6b2b0f785e88e013b33adec8cac08388;p=onig define SET_ENCLOSE_RECURSION() --- diff --git a/src/regcomp.c b/src/regcomp.c index 45fd0df..27d4161 100644 --- a/src/regcomp.c +++ b/src/regcomp.c @@ -2929,7 +2929,8 @@ subexp_recursive_check_trav(Node* node, ScanEnv* env) if (IS_ENCLOSE_CALLED(en)) { SET_ENCLOSE_STATUS(node, NST_MARK1); r = subexp_recursive_check(en->target); - if (r != 0) SET_ENCLOSE_STATUS(node, NST_RECURSION); + if (r != 0) + SET_ENCLOSE_RECURSION(node); CLEAR_ENCLOSE_STATUS(node, NST_MARK1); } } diff --git a/src/regparse.h b/src/regparse.h index c9d1fe8..2c7f72c 100644 --- a/src/regparse.h +++ b/src/regparse.h @@ -4,7 +4,7 @@ regparse.h - Oniguruma (regular expression library) **********************************************************************/ /*- - * Copyright (c) 2002-2007 K.Kosako + * Copyright (c) 2002-2017 K.Kosako * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -134,6 +134,7 @@ #define SET_ENCLOSE_STATUS(node,f) (node)->u.enclose.state |= (f) #define CLEAR_ENCLOSE_STATUS(node,f) (node)->u.enclose.state &= ~(f) +#define SET_ENCLOSE_RECURSION(node) (node)->u.enclose.state |= NST_RECURSION #define IS_ENCLOSE_CALLED(en) (((en)->state & NST_CALLED) != 0) #define IS_ENCLOSE_ADDR_FIXED(en) (((en)->state & NST_ADDR_FIXED) != 0)