]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
this wasn't right wrap in paren to get in multi pipe sep regexp.
authorBrian West <brian@freeswitch.org>
Tue, 11 Dec 2007 03:28:35 +0000 (03:28 +0000)
committerBrian West <brian@freeswitch.org>
Tue, 11 Dec 2007 03:28:35 +0000 (03:28 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@6620 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/switch_regex.c

index c2d595a22aa541ba0a81ab3f3276a241ae4624f3..c132ee1eb0f0474413a46d1cf07b39775221078f 100644 (file)
@@ -146,12 +146,7 @@ SWITCH_DECLARE(void) switch_perform_substitution(switch_regex_t *re, int match_c
                        }
                        index[z++] = '\0';
                        z = 0;
-                       if (match_count > 1) {
-                               int offset = match_count - 2;
-                               num = atoi(index) + offset;
-                       } else {
-                               num = atoi(index);
-                       }
+                       num = atoi(index);
 
                        if (pcre_copy_substring(field_data, ovector, match_count, num, replace, sizeof(replace)) > 0) {
                                switch_size_t r;