develooper Front page | perl.perl5.porters | Postings from July 2001

[PATCH] sub aaa { print shift}; undef %::;

Thread Next
From:
Simon Cozens
Date:
July 1, 2001 16:19
Subject:
[PATCH] sub aaa { print shift}; undef %::;
Message ID:
20010702001917.A14518@deep-dark-truthful-mirror
This stems a segfault coming from the above. There's a bug ID for this,
I think, but I'm afraid I'm too zonked to find it.

--- hv.c~	Mon Jul  2 00:13:03 2001
+++ hv.c	Mon Jul  2 00:13:17 2001
@@ -211,7 +211,7 @@
 
     /* entry = (HvARRAY(hv))[hash & (I32) HvMAX(hv)]; */
     entry = ((HE**)xhv->xhv_array)[hash & (I32) xhv->xhv_max];
-    for (; entry; entry = HeNEXT(entry)) {
+    for (; entry && HeKEY_hek(entry); entry = HeNEXT(entry)) {
 	if (HeHASH(entry) != hash)		/* strings can't be equal */
 	    continue;
 	if (HeKLEN(entry) != klen)

-- 
"He was a modest, good-humored boy.  It was Oxford that made him insufferable."

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About