summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2013-05-18 16:40:15 +0000
committerIngo Schwarze <schwarze@openbsd.org>2013-05-18 16:40:15 +0000
commitb9c640af8a3c806dde7a13727dab3d1715d35536 (patch)
tree118c53eb14ae024cb3fe613b435dbad84b78a085
parent175f2bb36c5cce9379ac422e788285ae27c036ee (diff)
downloadmandoc-b9c640af8a3c806dde7a13727dab3d1715d35536.tar.gz
Even though the size of a pointer should not depend on the type of the
data pointed to, pass the size of the right pointer type to calloc; cosmetic issue reported by Ulrich Spoerlein <uqs@spoerlein.net> found in Coverity Scan CID 978734. No binary change - ok cmp(1).
-rw-r--r--chars.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/chars.c b/chars.c
index 4aa92bac..e7947f51 100644
--- a/chars.c
+++ b/chars.c
@@ -77,7 +77,7 @@ mchars_alloc(void)
*/
tab = mandoc_malloc(sizeof(struct mchars));
- htab = mandoc_calloc(PRINT_HI - PRINT_LO + 1, sizeof(struct ln **));
+ htab = mandoc_calloc(PRINT_HI - PRINT_LO + 1, sizeof(struct ln *));
for (i = 0; i < LINES_MAX; i++) {
hash = (int)lines[i].code[0] - PRINT_LO;