]> git.xolatile.top Git - public-libhl.git/commitdiff
fixed retarded loop
authoranon <anon@anon.anon>
Fri, 25 Aug 2023 19:25:24 +0000 (21:25 +0200)
committeranon <anon@anon.anon>
Fri, 25 Aug 2023 19:25:24 +0000 (21:25 +0200)
source/regex.c

index 39d5c9556662b05ac9fbf003a0fac1a6d45bfc22..ece14def859f89a9393e96399a41e8687b1ae080 100644 (file)
@@ -314,7 +314,7 @@ static int compile_range(const char * const     range,
 static bool catch_(const regex_t * const regex,
                          int     * const state) {
 
-       for (size_t i = 0; i < regex->catch_table.element_size; i++){
+       for (size_t i = 0; i < regex->catch_table.element_count; i++){
                const offshoot_t * const offshoot = *(offshoot_t**)vector_get(&regex->catch_table, i);
                if (offshoot->in == *state) {
                        *state = offshoot->to;