summaryrefslogtreecommitdiff
path: root/gv.c
diff options
context:
space:
mode:
authorPerl 5 Porters <perl5-porters@africa.nicoh.com>1996-02-07 00:28:05 +0000
committerAndy Dougherty <doughera@lafcol.lafayette.edu>1996-02-07 00:28:05 +0000
commit377b8fbce4273bd1e167c823e634bcdca0ecaa69 (patch)
tree16136d8c6afeeca224b40fb701840eed4112f73d /gv.c
parent76c7ba2e4a4392e5e7538b69dfaf5c0656bdfaf4 (diff)
downloadperl-377b8fbce4273bd1e167c823e634bcdca0ecaa69.tar.gz
Old habits die hard :-)
Diffstat (limited to 'gv.c')
-rw-r--r--gv.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/gv.c b/gv.c
index 5b61bcc42f..7836d88dd8 100644
--- a/gv.c
+++ b/gv.c
@@ -428,7 +428,7 @@ I32 sv_type;
sv_type != SVt_PVGV &&
sv_type != SVt_PVFM &&
sv_type != SVt_PVIO &&
- !(len == 1 && sv_type == SVt_PV && index("ab",*name)) )
+ !(len == 1 && sv_type == SVt_PV && strchr("ab",*name)) )
{
gvp = (GV**)hv_fetch(stash,name,len,0);
if (!gvp ||
@@ -763,9 +763,8 @@ void
gp_free(gv)
GV* gv;
{
- IO *io;
- CV *cv;
GP* gp;
+ CV* cv;
if (!gv || !(gp = GvGP(gv)))
return;
@@ -782,10 +781,7 @@ GV* gv;
SvREFCNT_dec(gp->gp_sv);
SvREFCNT_dec(gp->gp_av);
SvREFCNT_dec(gp->gp_hv);
- if ((io = gp->gp_io) && SvTYPE(io) != SVTYPEMASK) {
- do_close(gv,FALSE);
- SvREFCNT_dec(io);
- }
+ SvREFCNT_dec(gp->gp_io);
if ((cv = gp->gp_cv) && !GvCVGEN(gv))
SvREFCNT_dec(cv);
SvREFCNT_dec(gp->gp_form);