repeatStoreSparseOptimalP: make diff a u32

As delta is a u32, we know diff will always fit within a u32 as well.
Silences a warning from Coverity.
This commit is contained in:
Justin Viiret 2015-11-10 16:18:42 +11:00 committed by Matthew Barr
parent f65170da5b
commit cf3ddd9e88

View File

@ -1414,7 +1414,8 @@ void repeatStoreSparseOptimalP(const struct RepeatInfo *info,
}
}
u64a diff = delta - patch * patch_size;
assert((u64a)patch * patch_size <= delta);
u32 diff = delta - patch * patch_size;
const u64a *repeatTable = getImplTable(info);
val += repeatTable[diff];