From: Tom Rini Date: Thu, 30 Jan 2020 20:40:45 -0500 Subject: [PATCHv3] cmd/gpt: Address error cases during gpt rename more correctly In-Reply-To: <20200121165338.24874-1-trini@konsulko.com> References: <20200121165338.24874-1-trini@konsulko.com> Message-ID: <20200131014045.GI13379@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 Tue, Jan 21, 2020 at 11:53:38AM -0500, Tom Rini wrote: > New analysis by the tool has shown that we have some cases where we > weren't handling the error exit condition correctly. When we ran into > the ENOMEM case we wouldn't exit the function and thus incorrect things > could happen. Rework the unwinding such that we don't need a helper > function now and free what we may have allocated. > > Fixes: 18030d04d25d ("GPT: fix memory leaks identified by Coverity") > Reported-by: Coverity (CID: 275475, 275476) > Cc: Alison Chaiken > Cc: Simon Goldschmidt > Cc: Jordy > Signed-off-by: Tom Rini > Reviewed-by: Simon Goldschmidt Applied to u-boot/master, thanks! -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 833 bytes Desc: not available URL: