diff --git a/jerry-core/ecma/operations/ecma-regexp-object.cpp b/jerry-core/ecma/operations/ecma-regexp-object.cpp index 4e21b9d98..66b462f74 100644 --- a/jerry-core/ecma/operations/ecma-regexp-object.cpp +++ b/jerry-core/ecma/operations/ecma-regexp-object.cpp @@ -297,13 +297,6 @@ re_match_regexp (re_matcher_ctx_t *re_ctx_p, /**< RegExp matcher context */ while ((op = re_get_opcode (&bc_p))) { - if (re_ctx_p->match_limit >= RE_EXECUTE_MATCH_LIMIT) - { - ret_value = ecma_raise_range_error ("RegExp executor steps limit is exceeded."); - return ret_value; - } - re_ctx_p->match_limit++; - switch (op) { case RE_OP_MATCH: @@ -1245,7 +1238,6 @@ ecma_regexp_exec_helper (ecma_value_t regexp_value, /**< RegExp object */ re_matcher_ctx_t re_ctx; re_ctx.input_start_p = iterator.buf_p; re_ctx.input_end_p = iterator.buf_p + iterator.buf_size; - re_ctx.match_limit = 0; re_ctx.recursion_depth = 0; /* 1. Read bytecode header and init regexp matcher context. */ diff --git a/jerry-core/ecma/operations/ecma-regexp-object.h b/jerry-core/ecma/operations/ecma-regexp-object.h index ef554cc6d..cdd88c6b2 100644 --- a/jerry-core/ecma/operations/ecma-regexp-object.h +++ b/jerry-core/ecma/operations/ecma-regexp-object.h @@ -34,11 +34,6 @@ */ #define RE_EXECUTE_RECURSION_LIMIT 1000 -/** - * Limit of RegExp execetur matching steps - */ -#define RE_EXECUTE_MATCH_LIMIT 10000 - /** * RegExp flags */ @@ -54,7 +49,6 @@ typedef struct lit_utf8_iterator_t *saved_p; /**< saved result string pointers, ECMA 262 v5, 15.10.2.1, State */ const lit_utf8_byte_t *input_start_p; /**< start of input pattern string */ const lit_utf8_byte_t *input_end_p; /**< end of input pattern string */ - uint32_t match_limit; /**< matching limit counter */ uint32_t recursion_depth; /**< recursion depth counter */ uint32_t num_of_captures; /**< number of capture groups */ uint32_t num_of_non_captures; /**< number of non-capture groups */