mirror of
https://github.com/torvalds/linux.git
synced 2026-05-03 05:52:38 -04:00
These error paths free a pointer and then dereference it on the next line to get the error code. Save the error code first and then free the memory. Fixes:3e4d5b30d2("drm/vkms: Allow to configure multiple CRTCs via configfs") Fixes:2f1734ba27("drm/vkms: Allow to configure multiple planes via configfs") Fixes:67d8cf92e1("drm/vkms: Allow to configure multiple encoders via configfs") Fixes:272acbca96("drm/vkms: Allow to configure multiple connectors via configfs") Fixes:13fc9b9745("drm/vkms: Add and remove VKMS instances via configfs") Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org> Reviewed-by: José Expósito <jose.exposito89@gmail.com> Link: https://lore.kernel.org/r/aPtfy2jCI_kb3Df7@stanley.mountain Signed-off-by: Louis Chauvet <louis.chauvet@bootlin.com>