From 1cc8897f728d8cf5649db5fac11ce1e0693340c7 Mon Sep 17 00:00:00 2001 From: "K.Kosako" Date: Wed, 12 Sep 2018 10:45:32 +0900 Subject: [PATCH] refactoring --- src/regcomp.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/regcomp.c b/src/regcomp.c index c0fd891..ee534ed 100644 --- a/src/regcomp.c +++ b/src/regcomp.c @@ -2520,10 +2520,8 @@ get_head_value_node(Node* node, int exact, regex_t* reg) if (sn->end <= sn->s) break; - if (exact != 0 && - !NODE_STRING_IS_RAW(node) && IS_IGNORECASE(reg->options)) { - } - else { + if (exact == 0 || + ! IS_IGNORECASE(reg->options) || NODE_STRING_IS_RAW(node)) { n = node; } } -- 2.50.1