diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | Src/params.c | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog index a9c47878b..893b16e2c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2016-11-11 Daniel Shahaf <d.s@daniel.shahaf.name> + + * 39874/0001: Src/params.c: setarrvalue: Remove needless + initialization. + 2016-11-10 Peter Stephenson <p.stephenson@samsung.com> * 39901: Src/exec.c, Test/C03traps.ztst: Exiting the left hand diff --git a/Src/params.c b/Src/params.c index ef72cba44..86a094b1f 100644 --- a/Src/params.c +++ b/Src/params.c @@ -2657,8 +2657,8 @@ setarrvalue(Value v, char **val) if (v->end <= pre_assignment_length) post_assignment_length += pre_assignment_length - v->end + 1; - p = new = (char **) zshcalloc(sizeof(char *) - * (post_assignment_length + 1)); + p = new = (char **) zalloc(sizeof(char *) + * (post_assignment_length + 1)); for (i = 0; i < v->start; i++) *p++ = i < pre_assignment_length ? ztrdup(*q++) : ztrdup(""); |