summaryrefslogtreecommitdiff
path: root/Documentation/x86
diff options
context:
space:
mode:
authorWen Yang <wenyang@linux.alibaba.com>2020-03-18 18:31:56 +0300
committerMiquel Raynal <miquel.raynal@bootlin.com>2020-03-25 01:01:36 +0300
commit49c64df880570034308e4a9a49c4bc95cf8cdb33 (patch)
tree1b150ed2a7b24f7a6c1d33c7fdfdd62150db85af /Documentation/x86
parent4da0ea71ea934af18db4c63396ba2af1a679ef02 (diff)
downloadlinux-49c64df880570034308e4a9a49c4bc95cf8cdb33.tar.xz
mtd: phram: fix a double free issue in error path
The variable 'name' is released multiple times in the error path, which may cause double free issues. This problem is avoided by adding a goto label to release the memory uniformly. And this change also makes the code a bit more cleaner. Fixes: 4f678a58d335 ("mtd: fix memory leaks in phram_setup") Signed-off-by: Wen Yang <wenyang@linux.alibaba.com> Cc: Joern Engel <joern@lazybastard.org> Cc: Miquel Raynal <miquel.raynal@bootlin.com> Cc: Richard Weinberger <richard@nod.at> Cc: Vignesh Raghavendra <vigneshr@ti.com> Cc: linux-mtd@lists.infradead.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Link: https://lore.kernel.org/linux-mtd/20200318153156.25612-1-wenyang@linux.alibaba.com
Diffstat (limited to 'Documentation/x86')
0 files changed, 0 insertions, 0 deletions