diff options
author | Nicholas Clark <nick@ccl4.org> | 2004-02-27 10:27:38 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2004-02-27 10:27:38 +0000 |
commit | 213ce8b3ce4d3f5793ccaac359c1025cb843f91b (patch) | |
tree | ff5a731d50bd37ce7674b6caa783a5232269b052 /hv.c | |
parent | dbb69c4a3755de9f9aec2aa6bc5e5af7e7b75f1a (diff) | |
download | perl-213ce8b3ce4d3f5793ccaac359c1025cb843f91b.tar.gz |
My re-implementation of hv_clear_placeholders was buggy - not sure why
the tests still passed. Fixed.
p4raw-id: //depot/perl@22391
Diffstat (limited to 'hv.c')
-rw-r--r-- | hv.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -1501,7 +1501,7 @@ Perl_hv_clear_placeholders(pTHX_ HV *hv) if (!entry) continue; - for (; entry; first=0, oentry = &HeNEXT(entry), entry = *oentry) { + for (; entry; entry = *oentry) { if (HeVAL(entry) == &PL_sv_placeholder) { *oentry = HeNEXT(entry); if (first && !*oentry) @@ -1519,6 +1519,9 @@ Perl_hv_clear_placeholders(pTHX_ HV *hv) HvPLACEHOLDERS(hv) = 0; return; } + } else { + oentry = &HeNEXT(entry); + first = 0; } } } while (--i >= 0); |