summaryrefslogtreecommitdiff
path: root/gv.h
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2007-03-01 16:09:31 +0000
committerNicholas Clark <nick@ccl4.org>2007-03-01 16:09:31 +0000
commit5be41be4072fd5cea66cae4e0e2cdfd32753ce89 (patch)
tree55aef838e528db3aa6a89729525524a15415cf07 /gv.h
parentec488c7f13c4270af54fc91b6664495b5831b7ec (diff)
downloadperl-5be41be4072fd5cea66cae4e0e2cdfd32753ce89.tar.gz
Don't SEGV when dumping an undefined typeglob. The HEK used to store
the GV's name can be NULL. p4raw-id: //depot/perl@30439
Diffstat (limited to 'gv.h')
-rw-r--r--gv.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/gv.h b/gv.h
index cbc68403e9..61af704d4e 100644
--- a/gv.h
+++ b/gv.h
@@ -113,7 +113,7 @@ Return the SV from the GV.
#define GvLINE(gv) (GvGP(gv)->gp_line)
#define GvFILE_HEK(gv) (GvGP(gv)->gp_file_hek)
-#define GvFILE(gv) HEK_KEY(GvFILE_HEK(gv))
+#define GvFILE(gv) (GvFILE_HEK(gv) ? HEK_KEY(GvFILE_HEK(gv)) : NULL)
#define GvFILEGV(gv) (gv_fetchfile(GvFILE(gv)))
#define GvEGV(gv) (GvGP(gv)->gp_egv)