Re: [PATCH] readelf: Fix division by zero in handle a relocation sections

2024-04-02 Thread Mark Wielaard
Hi Maks, On Sat, 2024-03-30 at 00:23 +0300, Maks Mishin wrote: > Variable 'sh_entsize', whose possible value set allows a zero value > by calling function 'gelf_fsize', is used as a denominator > in calculation of 'nentries' variable. > > Found by RASU JSC. Sorry, but I am going to stop reviewin

[PATCH] readelf: Fix division by zero in handle a relocation sections

2024-03-29 Thread Maks Mishin
Variable 'sh_entsize', whose possible value set allows a zero value by calling function 'gelf_fsize', is used as a denominator in calculation of 'nentries' variable. Found by RASU JSC. Signed-off-by: Maks Mishin --- src/readelf.c | 18 ++ 1 file changed, 18 insertions(+) diff -