summaryrefslogtreecommitdiff
path: root/perlio.c
diff options
context:
space:
mode:
authorLeon Timmermans <fawaka@gmail.com>2020-01-25 00:51:44 +0100
committerLeon Timmermans <fawaka@gmail.com>2020-01-26 16:10:23 +0100
commitd55a14617a40beb0dfda90ca2decc55918c0810c (patch)
tree003e2aa4e4a8f0d6847bf1e539b044927d73a90a /perlio.c
parentfd9c22e56536c51f0c621c365b440c3ca01c1ce4 (diff)
downloadperl-d55a14617a40beb0dfda90ca2decc55918c0810c.tar.gz
perlio.c: make :unix close method call underlaying layers as well
Diffstat (limited to 'perlio.c')
-rw-r--r--perlio.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/perlio.c b/perlio.c
index e6e4312949..39481eeb10 100644
--- a/perlio.c
+++ b/perlio.c
@@ -2818,6 +2818,7 @@ PerlIOUnix_close(pTHX_ PerlIO *f)
const int fd = PerlIOSelf(f, PerlIOUnix)->fd;
int code = 0;
if (PerlIOBase(f)->flags & PERLIO_F_OPEN) {
+ code = PerlIOBase_close(aTHX_ f);
if (PerlIOUnix_refcnt_dec(fd) > 0) {
PerlIOBase(f)->flags &= ~PERLIO_F_OPEN;
return 0;