diff options
author | 2007-10-08 04:15:15 +0000 | |
---|---|---|
committer | 2007-10-08 04:15:15 +0000 | |
commit | 8b13d1b4cd1cce9497115af5b6ee04d2fdc64db7 (patch) | |
tree | e8df1cd15504c110c5c1fc72174593266e7bb4b9 /sys/xfs | |
parent | Introduce %z for printf(9), like %z for printf(3). Used to print (diff) | |
download | wireguard-openbsd-8b13d1b4cd1cce9497115af5b6ee04d2fdc64db7.tar.xz wireguard-openbsd-8b13d1b4cd1cce9497115af5b6ee04d2fdc64db7.zip |
More simple memset(,0,) -> M_ZERO changes. In this batch move to
size(*p) as the first malloc() parameter where p is declared locally
and thus easy to check. Add M_ZERO to gpe_table allocation in acpi.c
even though there is no obvious bzero or memset nearby.
Diffstat (limited to 'sys/xfs')
-rw-r--r-- | sys/xfs/xfs_vnodeops-common.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/xfs/xfs_vnodeops-common.c b/sys/xfs/xfs_vnodeops-common.c index ecb61f8d839..9531c0a719a 100644 --- a/sys/xfs/xfs_vnodeops-common.c +++ b/sys/xfs/xfs_vnodeops-common.c @@ -931,12 +931,11 @@ xfs_symlink_common(struct vnode *dvp, NNPFSDEB(XDEBVNOPS, ("xfs_symlink: %s\n", name)); - msg = malloc(sizeof(struct xfs_message_symlink), M_TEMP, M_WAITOK); + msg = malloc(sizeof(*msg), M_TEMP, M_WAITOK | M_ZERO); if (msg == NULL) { error = ENOMEM; goto done; } - memset(msg, 0, sizeof(*msg)); msg->header.opcode = NNPFS_MSG_SYMLINK; msg->parent_handle = xn->handle; |