mirror of
https://git.openafs.org/openafs.git
synced 2025-01-21 08:20:16 +00:00
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:
parent
e202822b8e
commit
408afc5690
@ -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));
|
||||||
|
Loading…
Reference in New Issue
Block a user