This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
356373a
)
[perl #30509] use encoding and "eq" cause memory leak
author
Dave Mitchell
<davem@fdisolutions.com>
Mon, 28 Jun 2004 22:50:01 +0000
(22:50 +0000)
committer
Dave Mitchell
<davem@fdisolutions.com>
Mon, 28 Jun 2004 22:50:01 +0000
(22:50 +0000)
Perl_sv_eq() was creating a temp and not always freeing it
p4raw-id: //depot/perl@23006
sv.c
patch
|
blob
|
blame
|
history
diff --git
a/sv.c
b/sv.c
index
371d17e
..
db872e1
100644
(file)
--- a/
sv.c
+++ b/
sv.c
@@
-6639,8
+6639,10
@@
Perl_sv_eq(pTHX_ register SV *sv1, register SV *sv2)
pv1 = SvPV(svrecode, cur1);
}
/* Now both are in UTF-8. */
- if (cur1 != cur2)
+ if (cur1 != cur2) {
+ SvREFCNT_dec(svrecode);
return FALSE;
+ }
}
else {
bool is_utf8 = TRUE;