From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pj1-f47.google.com (mail-pj1-f47.google.com [209.85.216.47]) by mx.groups.io with SMTP id smtpd.web11.3114.1676660823419940607 for ; Fri, 17 Feb 2023 11:07:03 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20210112 header.b=i5n/AXDe; spf=pass (domain: gmail.com, ip: 209.85.216.47, mailfrom: pedro.falcato@gmail.com) Received: by mail-pj1-f47.google.com with SMTP id p15-20020a17090a2d8f00b00233ceae8407so2147478pjd.3 for ; Fri, 17 Feb 2023 11:07:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=gIPXm4YCblo/geEiil0LT1uC9qP0z4dw1QosNtL6NVA=; b=i5n/AXDeCskozKBfpCkZ9K72Gc0+I6IWyVgNNrX/kw+itTFrlZu0Pc6gLn8aWOLdoi kpDvsFXbOAAIFtiUFGJQo4W37HjErxdjyJS3H7+Ah/yFn7lVI+geiCExIeprV7AXFR7m uhkJ3aKK4UGKXjRljXXg8N7aMOk86O7kWa3aZr0CPKujeR6in7Ez7baJrpDJYOArHMIq IGXsNu6F1Wg76FLt/zl7Po6cKFb1MGUz1mB7qoxnegM+pWjrWy1xU9vpZOnmwQSgWVNp i3fSv2zI/kM7fHlf9BE2e1SpKUa8hAoqiOQ5lCvZVo/tR5A/+5Y9lC+7FcmgBJNgmX+L +g2g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=gIPXm4YCblo/geEiil0LT1uC9qP0z4dw1QosNtL6NVA=; b=mc8JqV0DjJsA1jsP2Q5mvQ4luWoQCJuPKdA/8dOSnOxnmBCE39KMjPkeiXnppTOZ/C v6YuIoRB6rGNPyQR15v54ALTw0Sgj/H/O9xV7zMI2O2MltwSJI/DEJErn5HKSpQ1/bZ3 /O7HYPhc0UWKDpbB1hAys7B5J+RE91o8g0zCM0Nb6UEnIuxdwWHPqzdD30kH9jlsjOWx jJNxCowfT4EPk5Q1VvFSu/A9zdVNeoAT6h37qlW/BKH0zg0zEcLvDZ9pUIBW6xIHmCFB xeCjoZcWP9/Z8wzoS73lD4uWCQ1RiLSOdLE2W8MQAeZOf20i3nwbEUoFLN/HF8HyubwY jxJg== X-Gm-Message-State: AO0yUKXOyXJfey+QL1iwto7VdyRQF5wJInrMRJ1THvCr8VvmHhPj8nHt 2QfTuSDCiAhURkwMmXQWJDFjrsOUr1cMG8Gsy+k= X-Google-Smtp-Source: AK7set8RfOs4ZwOQM+/WqxEkg1DbU1AxJ6kD2yaR820rcvgDdcYMcHubESpaxdH/yj11P0MmhmKNEnmqbTWw043ra34= X-Received: by 2002:a17:90b:3a8f:b0:234:117c:970f with SMTP id om15-20020a17090b3a8f00b00234117c970fmr1748648pjb.28.1676660822944; Fri, 17 Feb 2023 11:07:02 -0800 (PST) MIME-Version: 1.0 References: <20230217085647.70781-1-savvamtr@gmail.com> In-Reply-To: From: "Pedro Falcato" Date: Fri, 17 Feb 2023 19:06:51 +0000 Message-ID: Subject: Re: [edk2-platforms][PATCH v4 1/1] Ext4Pkg: Fixes double-free in Ext4ReadSymlink To: Savva Mitrofanov Cc: devel@edk2.groups.io, =?UTF-8?Q?Marvin_H=C3=A4user?= , Vitaly Cheptsov Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, Feb 17, 2023 at 5:34 PM Pedro Falcato wro= te: > > On Fri, Feb 17, 2023 at 8:56 AM Savva Mitrofanov wro= te: > > > > The SymlinkTmp was deallocated unconditionally, so we shouldn't free it > > again on EFI_ERROR > > > > Cc: Marvin H=C3=A4user > > Cc: Pedro Falcato > > Cc: Vitaly Cheptsov > > Fixes: e81432fbacb7 ("Ext4Pkg: Add symbolic links support") > > Signed-off-by: Savva Mitrofanov > > --- > > Features/Ext4Pkg/Ext4Dxe/Symlink.c | 1 - > > 1 file changed, 1 deletion(-) > > > > diff --git a/Features/Ext4Pkg/Ext4Dxe/Symlink.c b/Features/Ext4Pkg/Ext4= Dxe/Symlink.c > > index 1189a99ded2b..d80cb9fff92e 100644 > > --- a/Features/Ext4Pkg/Ext4Dxe/Symlink.c > > +++ b/Features/Ext4Pkg/Ext4Dxe/Symlink.c > > @@ -243,7 +243,6 @@ Ext4ReadSymlink ( > > Status > > )); > > FreePool (Symlink16Tmp); > > - FreePool (SymlinkTmp); > > return Status; > > } > > > > -- > > 2.39.1 > > > > Thank you! > > Reviewed-by: Pedro Falcato > > -- > Pedro Pushed to edk2-platforms as 81ec441, with minor corrections (Fixes -> Fix, as per the standard imperative commit message style). Thanks! --=20 Pedro