summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Mitchell <davem@fdisolutions.com>2006-04-03 09:56:29 +0000
committerDave Mitchell <davem@fdisolutions.com>2006-04-03 09:56:29 +0000
commitad65c0754dcb913eeecdd57abf05d41b6889161b (patch)
treef0277bace19c77a8bfbe0af5df4e053f30b7ca3b
parentf84c484e31ca71701038f389bc647f43cdbdfd43 (diff)
downloadperl-ad65c0754dcb913eeecdd57abf05d41b6889161b.tar.gz
undo #27700 and add a missing Safefree()
p4raw-id: //depot/perl@27702
-rw-r--r--regexec.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/regexec.c b/regexec.c
index 1d334b3e49..bbec763bb0 100644
--- a/regexec.c
+++ b/regexec.c
@@ -4556,10 +4556,12 @@ exit_level:
/* free all slabs above current one */
if (orig_slab->next) {
- regmatch_slab *sl = orig_slab->next;
+ regmatch_slab *osl, *sl = orig_slab->next;
orig_slab->next = NULL;
while (sl) {
+ osl = sl;
sl = sl->next;
+ Safefree(osl);
}
}