diff options
author | uqs <uqs@FreeBSD.org> | 2015-12-29 11:24:35 +0000 |
---|---|---|
committer | uqs <uqs@FreeBSD.org> | 2015-12-29 11:24:35 +0000 |
commit | d4f2c120c09150a7012ceea91a74ea068aa5a9c6 (patch) | |
tree | f9218ab7a14e2a493fba0f91eb498c3952cb9ce3 /sbin/mount | |
parent | 850d0994e48b0ef68d33875e26326d44931fcf1e (diff) | |
download | FreeBSD-src-d4f2c120c09150a7012ceea91a74ea068aa5a9c6.zip FreeBSD-src-d4f2c120c09150a7012ceea91a74ea068aa5a9c6.tar.gz |
Fix type mismatches for malloc(3) and Co.
Found by: clang static analyzer
Reviewed by: ed
Differential Revision: https://reviews.freebsd.org/D4722
Diffstat (limited to 'sbin/mount')
-rw-r--r-- | sbin/mount/mount.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sbin/mount/mount.c b/sbin/mount/mount.c index 8c68467..debe354 100644 --- a/sbin/mount/mount.c +++ b/sbin/mount/mount.c @@ -541,7 +541,7 @@ append_arg(struct cpa *sa, char *arg) { if (sa->c + 1 == sa->sz) { sa->sz = sa->sz == 0 ? 8 : sa->sz * 2; - sa->a = realloc(sa->a, sizeof(sa->a) * sa->sz); + sa->a = realloc(sa->a, sizeof(*sa->a) * sa->sz); if (sa->a == NULL) errx(1, "realloc failed"); } |