libelf: add an assert that msz is non-zero
Reported by: Coverity CID: 976023
This commit is contained in:
parent
e592841459
commit
f2911fa4a3
@ -808,6 +808,7 @@ _libelf_write_scn(Elf *e, unsigned char *nf, struct _Elf_Extent *ex)
|
||||
|
||||
assert(d->d_buf != NULL);
|
||||
assert(d->d_version == e->e_version);
|
||||
assert(msz != 0);
|
||||
assert(d->d_size % msz == 0);
|
||||
|
||||
nobjects = (size_t) (d->d_size / msz);
|
||||
|
Loading…
x
Reference in New Issue
Block a user