mirror of
git://git.yoctoproject.org/linux-yocto.git
synced 2025-10-23 07:23:12 +02:00
selftests: ALSA: fix memory leak in utimer test
[ Upstream commit6260da0468
] Free the malloc'd buffer in TEST_F(timer_f, utimer) to prevent memory leak. Fixes:1026392d10
("selftests: ALSA: Cover userspace-driven timers with test") Reported-by: Jun Zhan <zhanjun@uniontech.com> Signed-off-by: WangYuli <wangyuli@uniontech.com> Link: https://patch.msgid.link/DE4D931FCF54F3DB+20250731100222.65748-1-wangyuli@uniontech.com Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
6f7ac9c5ad
commit
0a98771d1e
|
@ -135,6 +135,7 @@ TEST_F(timer_f, utimer) {
|
|||
pthread_join(ticking_thread, NULL);
|
||||
ASSERT_EQ(total_ticks, TICKS_COUNT);
|
||||
pclose(rfp);
|
||||
free(buf);
|
||||
}
|
||||
|
||||
TEST(wrong_timers_test) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user