summaryrefslogtreecommitdiff
path: root/usr.sbin/rpc.lockd
diff options
context:
space:
mode:
authorUlrich Spörlein <uqs@FreeBSD.org>2015-12-29 11:24:41 +0000
committerUlrich Spörlein <uqs@FreeBSD.org>2015-12-29 11:24:41 +0000
commitc9e1c304c1f5553fb45f2851840cb6ee6e39243f (patch)
treeb886de70650826ff015bc0343d808ffba0f524fd /usr.sbin/rpc.lockd
parente96092e82bbfbee2350ed4061ae1db9b95ef7156 (diff)
downloadsrc-test2-c9e1c304c1f5553fb45f2851840cb6ee6e39243f.tar.gz
src-test2-c9e1c304c1f5553fb45f2851840cb6ee6e39243f.zip
Fix type mismatches for malloc(3) and Co.
This is rather pedantic, as for most architectures it holds that sizeof(type *) == sizeof(type **) Found by: clang static analyzer Reviewed by: ed Differential Revision: https://reviews.freebsd.org/D4722
Notes
Notes: svn path=/head/; revision=292864
Diffstat (limited to 'usr.sbin/rpc.lockd')
-rw-r--r--usr.sbin/rpc.lockd/lockd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/rpc.lockd/lockd.c b/usr.sbin/rpc.lockd/lockd.c
index 4f1347ef924b..88b19b71e2bb 100644
--- a/usr.sbin/rpc.lockd/lockd.c
+++ b/usr.sbin/rpc.lockd/lockd.c
@@ -220,7 +220,7 @@ main(int argc, char **argv)
* list.
*/
if (nhosts == 0) {
- hosts = malloc(sizeof(char**));
+ hosts = malloc(sizeof(char *));
if (hosts == NULL)
out_of_mem();