openwrt/tools/firmware-utils
Kevin Darbyshire-Bryant 27f4559281 firmware-utils: fix coverity zytrx.c resource leak
fix coverity resource leak warning:

    	*len = stat.st_size;
    	mapped = mmap(NULL, stat.st_size, PROT_READ, MAP_SHARED, fd, 0);
    	if (close(fd) < 0)
CID 1484880:  Resource leaks  (RESOURCE_LEAK)
Variable "mapped" going out of scope leaks the storage it points to.
    		return NULL;
    	return mapped;
    }

Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
(cherry picked from commit baf2a50ef3)
2021-06-10 17:09:35 +02:00
..
src firmware-utils: fix coverity zytrx.c resource leak 2021-06-10 17:09:35 +02:00
Makefile firmware-utils: zytrx: Add util for ZyXEL specific header 2021-06-10 17:09:35 +02:00