diff options
author | Nicholas Clark <nick@ccl4.org> | 2006-03-05 19:07:12 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2006-03-05 19:07:12 +0000 |
commit | ae8cc45f19735266b98e68ac96abd0c5050c140f (patch) | |
tree | 2a7bb46f4e08a63e1a40ec2c267201e32414866e /gv.h | |
parent | 4164be692ecdc110086abd011eb6e1c41f13ed34 (diff) | |
download | perl-ae8cc45f19735266b98e68ac96abd0c5050c140f.tar.gz |
Perl_gv_name_set should not leak the old HEK. Allow the flag GV_ADD
to simplify GV initialisation.
p4raw-id: //depot/perl@27382
Diffstat (limited to 'gv.h')
-rw-r--r-- | gv.h | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -187,7 +187,9 @@ Return the SV from the GV. /* * symbol creation flags, for use in gv_fetchpv() and get_*v() */ -#define GV_ADD 0x01 /* add, if symbol not already there */ +#define GV_ADD 0x01 /* add, if symbol not already there + For gv_name_set, adding a HEK for the first + time, so don't try to free what's there. */ #define GV_ADDMULTI 0x02 /* add, pretending it has been added already */ #define GV_ADDWARN 0x04 /* add, but warn if symbol wasn't already there */ #define GV_ADDINEVAL 0x08 /* add, as though we're doing so within an eval */ |