diff options
Diffstat (limited to 'usr.bin/patch/inp.c')
-rw-r--r-- | usr.bin/patch/inp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/patch/inp.c b/usr.bin/patch/inp.c index 19536da0f5f8..2c955d0c8377 100644 --- a/usr.bin/patch/inp.c +++ b/usr.bin/patch/inp.c @@ -23,7 +23,7 @@ * -C option added in 1998, original code by Marc Espie, based on FreeBSD * behaviour * - * $OpenBSD: inp.c,v 1.36 2012/04/10 14:46:34 ajacoutot Exp $ + * $OpenBSD: inp.c,v 1.44 2015/07/26 14:32:19 millert Exp $ * $FreeBSD$ */ @@ -118,7 +118,7 @@ reallocate_lines(size_t *lines_allocated) size_t new_size; new_size = *lines_allocated * 3 / 2; - p = realloc(i_ptr, (new_size + 2) * sizeof(char *)); + p = reallocarray(i_ptr, new_size + 2, sizeof(char *)); if (p == NULL) { /* shucks, it was a near thing */ munmap(i_womp, i_size); i_womp = NULL; |