summaryrefslogtreecommitdiff
path: root/mro.c
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@gmail.com>2007-04-19 17:28:38 +0000
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>2007-04-19 17:28:38 +0000
commit183086bed615206c8d847db3e3e9fcf0cfd1ea53 (patch)
treece790ced6cc6ecfd9d99f58fde12d7a4746f8cc6 /mro.c
parent9fe4aecf05bd9db46d8bc10b5508a11d745944f5 (diff)
downloadperl-183086bed615206c8d847db3e3e9fcf0cfd1ea53.tar.gz
Simpler version, and that zeroes the allocated memory
p4raw-id: //depot/perl@30988
Diffstat (limited to 'mro.c')
-rw-r--r--mro.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mro.c b/mro.c
index 9a750fe0c8..1fa2a3792a 100644
--- a/mro.c
+++ b/mro.c
@@ -31,7 +31,7 @@ Perl_mro_meta_init(pTHX_ HV* stash)
assert(stash);
assert(HvAUX(stash));
assert(!(HvAUX(stash)->xhv_mro_meta));
- Newxc(newmeta, sizeof(struct mro_meta), char, struct mro_meta);
+ Newxz(newmeta, 1, struct mro_meta);
HvAUX(stash)->xhv_mro_meta = newmeta;
newmeta->sub_generation = 1;
@@ -58,7 +58,7 @@ Perl_mro_meta_dup(pTHX_ struct mro_meta* smeta, CLONE_PARAMS* param)
assert(smeta);
- Newxc(newmeta, sizeof(struct mro_meta), char, struct mro_meta);
+ Newxz(newmeta, 1, struct mro_meta);
newmeta->mro_which = smeta->mro_which;
newmeta->sub_generation = smeta->sub_generation;