mirror of
https://github.com/radareorg/radare2.git
synced 2024-12-01 09:00:46 +00:00
COFF: handle empty sections (#447) ##bin
This commit is contained in:
parent
77455b1c64
commit
59ad3b3c0b
@ -202,8 +202,12 @@ static bool r_bin_coff_init_scn_va(struct r_bin_coff_obj *obj) {
|
||||
int i;
|
||||
ut64 va = 0;
|
||||
for (i = 0; i < obj->hdr.f_nscns; i++) {
|
||||
ut64 sz = obj->scn_hdrs[i].s_size;
|
||||
if (sz < 16) {
|
||||
sz = 16;
|
||||
}
|
||||
obj->scn_va[i] = va;
|
||||
va += obj->scn_hdrs[i].s_size;
|
||||
va += sz;
|
||||
va = R_ROUND (va, 16ULL);
|
||||
}
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user