From b6eb8cf03f5850d13ec21101ec1783a444aefcab Mon Sep 17 00:00:00 2001 From: Adam Richter Date: Wed, 1 May 2019 15:22:02 -0700 Subject: [PATCH] hw/xfree86/os-support/linux/lnx_agp.c xf86GetAGPInfo(): free(info) in an error path, caught by cppcheck. --- hw/xfree86/os-support/linux/lnx_agp.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/xfree86/os-support/linux/lnx_agp.c b/hw/xfree86/os-support/linux/lnx_agp.c index e47bbfa1a..3aec5397c 100644 --- a/hw/xfree86/os-support/linux/lnx_agp.c +++ b/hw/xfree86/os-support/linux/lnx_agp.c @@ -143,6 +143,7 @@ xf86GetAGPInfo(int screenNum) xf86DrvMsg(screenNum, X_ERROR, "xf86GetAGPInfo: AGPIOC_INFO failed (%s)\n", strerror(errno)); + free(info); return NULL; }