Commit 9cff2d1e39bca4e456a61a3395611cafe2f8969e

Authored by Simon Glass
Committed by Tom Rini
1 parent a6f70a3d14

mkimage: Fix munmap() call when importing data

The munmap() call unmaps the wrong memory buffer. Fix it.

Reported-by: Coverity (CID: 138505)
Reported-by: Coverity (CID: 138495)
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Tom Rini <trini@konsulko.com>

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

... ... @@ -517,7 +517,7 @@
517 517 }
518 518 }
519 519  
520   - munmap(fdt, sbuf.st_size);
  520 + munmap(old_fdt, sbuf.st_size);
521 521 close(fd);
522 522  
523 523 /* Pack the FDT and place the data after it */