aboutsummaryrefslogtreecommitdiffstats
path: root/regcomp.c
diff options
context:
space:
mode:
authorYusuke Endoh <mame@ruby-lang.org>2022-03-24 16:59:11 +0900
committerYusuke Endoh <mame@ruby-lang.org>2022-03-30 16:50:46 +0900
commitffc3b37f969a779f93b8f8a5b3591b4ef7de1538 (patch)
tree25b2d942e8eb2c4a73043773edfcfd6c0d709155 /regcomp.c
parent23530d68cb04aed9c2f59a050523b0193ee2d0c1 (diff)
downloadruby-ffc3b37f969a779f93b8f8a5b3591b4ef7de1538.tar.gz
re.c: Add Regexp.timeout= and Regexp.timeout
[Feature #17837]
Diffstat (limited to 'regcomp.c')
-rw-r--r--regcomp.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/regcomp.c b/regcomp.c
index d51163103e..3e65c9d2e3 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -5973,6 +5973,9 @@ onig_reg_init(regex_t* reg, OnigOptionType option,
(reg)->name_table = (void* )NULL;
(reg)->case_fold_flag = case_fold_flag;
+
+ (reg)->timelimit = 0;
+
return 0;
}