Permalink
Browse files

OP_MULTICONCAT: fix AIX

The OP_MULTICONCAT work broke AIX builds because it turns out that
PerlMemShared_malloc() isn't safe (in the sense of safemalloc());
i.e. on AIX, PerlMemShared_malloc(0) returns NULL.
  • Loading branch information...
iabyn committed Nov 14, 2017
1 parent 8f2f8ba commit 6623aa6a6b84e22d8d692825a9686006b6811b78
Showing with 1 addition and 1 deletion.
  1. +1 −1 op.c
View
2 op.c
@@ -3043,7 +3043,7 @@ S_maybe_multiconcat(pTHX_ OP *o)
+ ((nargs + 1) * (variant ? 2 : 1))
)
);
const_str = (char *)PerlMemShared_malloc(total_len);
const_str = (char *)PerlMemShared_malloc(total_len ? total_len : 1);
/* Extract all the non-const expressions from the concat tree then
* dispose of the old tree, e.g. convert the tree from this:

0 comments on commit 6623aa6

Please sign in to comment.