vol: Call memset with the correct size

Call memset with the size of the structure we're initialising to 0,
and not the size of the pointer to that structure.

Caught by clang's new warnings.

Change-Id: I8cded7bed4e289e9603778e06873f94fd3924aa8
Reviewed-on: http://gerrit.openafs.org/7083
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
This commit is contained in:
Simon Wilkinson 2012-03-30 19:31:10 +01:00 committed by Derrick Brashear
parent e202822b8e
commit 408afc5690

View File

@ -3323,7 +3323,7 @@ DistilVnodeEssence(struct SalvInfo *salvinfo, VolumeId rwVId,
if (class != vLarge) { if (class != vLarge) {
VnodeId vnodeNumber = bitNumberToVnodeNumber(vnodeIndex, class); VnodeId vnodeNumber = bitNumberToVnodeNumber(vnodeIndex, class);
vip->nAllocatedVnodes--; vip->nAllocatedVnodes--;
memset(vnode, 0, sizeof(vnode)); memset(vnode, 0, sizeof(*vnode));
IH_IWRITE(salvinfo->vnodeInfo[vSmall].handle, IH_IWRITE(salvinfo->vnodeInfo[vSmall].handle,
vnodeIndexOffset(vcp, vnodeNumber), vnodeIndexOffset(vcp, vnodeNumber),
(char *)&vnode, sizeof(vnode)); (char *)&vnode, sizeof(vnode));