summaryrefslogtreecommitdiff
path: root/perlio.c
diff options
context:
space:
mode:
authorZefram <zefram@fysh.org>2017-11-13 07:52:35 +0000
committerZefram <zefram@fysh.org>2017-11-13 07:54:34 +0000
commitd09f14bff00cc465825c16e4e810687132f34070 (patch)
tree68d36528b4bc457d106150fe4393ac06e176b461 /perlio.c
parent8f9371749363490230e8a3114a27b7f29d52f12e (diff)
downloadperl-d09f14bff00cc465825c16e4e810687132f34070.tar.gz
avoid redundant initialisation around Newxz()
Reduce Newxz() to Newx() where all relevant parts of the memory are being explicitly initialised, and don't explicitly zero memory that was already zeroed. [perl #36078]
Diffstat (limited to 'perlio.c')
-rw-r--r--perlio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/perlio.c b/perlio.c
index 054f210e37..e7dd7f5f18 100644
--- a/perlio.c
+++ b/perlio.c
@@ -4281,7 +4281,7 @@ PerlIOBuf_get_base(pTHX_ PerlIO *f)
if (!b->buf) {
if (!b->bufsiz)
b->bufsiz = PERLIOBUF_DEFAULT_BUFSIZ;
- Newxz(b->buf,b->bufsiz, STDCHAR);
+ Newx(b->buf,b->bufsiz, STDCHAR);
if (!b->buf) {
b->buf = (STDCHAR *) & b->oneword;
b->bufsiz = sizeof(b->oneword);