From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tom Rini Date: Wed, 5 Aug 2020 16:28:28 -0400 Subject: [PATCH v2] fit_image: Use calloc() to fix reproducibility issue In-Reply-To: <20200728000313.31130-1-festevam@gmail.com> References: <20200728000313.31130-1-festevam@gmail.com> Message-ID: <20200805202828.GI6965@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Mon, Jul 27, 2020 at 09:03:13PM -0300, Fabio Estevam wrote: > Vagrant Cascadian reported that mx6cuboxi target no longer builds > reproducibility on Debian. > > One example of builds mismatches: > > 00096680: 696e 6700 736f 756e 642d 6461 6900 6465 ing.sound-dai.de > -00096690: 7465 6374 2d67 7069 6f73 0000 tect-gpios.. > +00096690: 7465 6374 2d67 7069 6f73 0061 tect-gpios.a > > This problem happens because all the buffers in fit_image.c are > allocated via malloc(), which does not zero out the allocated buffer. > > Using calloc() fixes this unpredictable behaviour as it guarantees > that the allocated buffer are zero initialized. > > Reported-by: Vagrant Cascadian > Suggested-by: Tom Rini > Signed-off-by: Fabio Estevam > Tested-by: Vagrant Cascadian Applied to u-boot/master, thanks! -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: