don't leak the deconstructed var name
Jesse Luehrs [Fri, 12 Nov 2010 20:26:25 +0000 (14:26 -0600)]
Stash.xs

index aefe1b1..42b3ee5 100644 (file)
--- a/Stash.xs
+++ b/Stash.xs
@@ -120,6 +120,7 @@ void _deconstruct_variable_hash(HV *variable, varspec_t *varspec)
         croak("The 'name' key is required in variable specs");
 
     varspec->name = savesvpv(*val);
+    SAVEFREEPV(varspec->name);
 
     val = hv_fetch(variable, "sigil", 5, 0);
     if (!val)