]> granicus.if.org Git - onig/commitdiff
small code refactoring
authorK.Kosako <kosako@sofnec.co.jp>
Thu, 15 Jun 2017 04:23:27 +0000 (13:23 +0900)
committerK.Kosako <kosako@sofnec.co.jp>
Thu, 15 Jun 2017 04:23:27 +0000 (13:23 +0900)
src/regcomp.c

index 68ecbbc7b71496728951922d07c00a64ba664ff8..b53c32cb097a21df204f024e4cd5d12e8196dae7 100644 (file)
@@ -5427,11 +5427,9 @@ onig_compile(regex_t* reg, const UChar* pattern, const UChar* pattern_end,
     if (r  < 0) goto err_unset;
     r = infinite_recursive_call_check_trav(root, &scan_env);
     if (r != 0) goto err_unset;
-
-    reg->num_call = scan_env.num_call;
   }
-  else
-    reg->num_call = 0;
+
+  reg->num_call = scan_env.num_call;
 #endif
 
   r = setup_tree(root, reg, 0, &scan_env);