summaryrefslogtreecommitdiff
path: root/pp_sys.c
diff options
context:
space:
mode:
authorDave Mitchell <davem@fdisolutions.com>2004-01-16 16:39:17 +0000
committerDave Mitchell <davem@fdisolutions.com>2004-01-16 16:39:17 +0000
commit0bd0581c0da439d1bc9686c40ce8eabbab0f37cd (patch)
tree44de1a96a4d02bb54aa1f82f82bddb6fba701ada /pp_sys.c
parenta1b950687051c32e26de8681b0ed639ad32adfb4 (diff)
downloadperl-0bd0581c0da439d1bc9686c40ce8eabbab0f37cd.tar.gz
[perl #8698] format bug with undefined _TOP
name of format_TOP now derived from the name of the current filehandle rather then the name of the format associetd with that handle p4raw-id: //depot/perl@22162
Diffstat (limited to 'pp_sys.c')
-rw-r--r--pp_sys.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pp_sys.c b/pp_sys.c
index 259c926dc3..3de073d3a7 100644
--- a/pp_sys.c
+++ b/pp_sys.c
@@ -1327,7 +1327,7 @@ PP(pp_leavewrite)
if (!IoTOP_NAME(io)) {
if (!IoFMT_NAME(io))
IoFMT_NAME(io) = savepv(GvNAME(gv));
- topname = sv_2mortal(Perl_newSVpvf(aTHX_ "%s_TOP", IoFMT_NAME(io)));
+ topname = sv_2mortal(Perl_newSVpvf(aTHX_ "%s_TOP", GvNAME(gv)));
topgv = gv_fetchpv(SvPVX(topname), FALSE, SVt_PVFM);
if ((topgv && GvFORM(topgv)) ||
!gv_fetchpv("top",FALSE,SVt_PVFM))