Patch "perf pmu: zfree() expects a pointer to a pointer to zero it after freeing its contents" has been added to the 6.2-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    perf pmu: zfree() expects a pointer to a pointer to zero it after freeing its contents

to the 6.2-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     perf-pmu-zfree-expects-a-pointer-to-a-pointer-to-zer.patch
and it can be found in the queue-6.2 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 736161e8770e7db680d55898abaf2af0e2080e83
Author: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx>
Date:   Wed Apr 12 10:23:35 2023 -0300

    perf pmu: zfree() expects a pointer to a pointer to zero it after freeing its contents
    
    [ Upstream commit 57f14b5ae1a97537f2abd2828ee7212cada7036e ]
    
    An audit showed just this one problem with zfree(), fix it.
    
    Fixes: 9fbc61f832ebf432 ("perf pmu: Add support for PMU capabilities")
    Signed-off-by: Arnaldo Carvalho de Melo <acme@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/tools/perf/util/pmu.c b/tools/perf/util/pmu.c
index 2bdeb89352e7a..be49be366c05c 100644
--- a/tools/perf/util/pmu.c
+++ b/tools/perf/util/pmu.c
@@ -1833,7 +1833,7 @@ static int perf_pmu__new_caps(struct list_head *list, char *name, char *value)
 	return 0;
 
 free_name:
-	zfree(caps->name);
+	zfree(&caps->name);
 free_caps:
 	free(caps);
 



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux