regcomp.c: Initialize a variable more conservatively
authorKarl Williamson <khw@cpan.org>
Sun, 18 Nov 2018 21:52:15 +0000 (14:52 -0700)
committerKarl Williamson <khw@cpan.org>
Tue, 27 Nov 2018 05:08:09 +0000 (22:08 -0700)
It doesn't matter currently, but thes variable shouldn't be TRUE unless
/i is in effect.

regcomp.c

index 4a87c94..d8e7de6 100644 (file)
--- a/regcomp.c
+++ b/regcomp.c
@@ -13725,7 +13725,7 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
              * contain only above-Latin1 characters (hence must be in UTF8),
              * which don't participate in folds with Latin1-range characters,
              * as the latter's folds aren't known until runtime. */
-            bool maybe_exactfu = TRUE;
+            bool maybe_exactfu = FOLD;
 
             /* Allocate an EXACT node.  The node_type may change below to
              * another EXACTish node, but since the size of the node doesn't
@@ -13862,7 +13862,7 @@ S_regatom(pTHX_ RExC_state_t *pRExC_state, I32 *flagp, U32 depth)
                             if (! maybe_exactfu) {
                                 len = 0;
                                 s = s0;
-                                maybe_exactfu = TRUE;   /* Prob. unnecessary */
+                                maybe_exactfu = FOLD;   /* Prob. unnecessary */
                                 goto reparse;
                             }
                         }