]> git.baikalelectronics.ru Git - kernel.git/commit
drm/vmwgfx: fix memory leak when too many retries have occurred
authorColin Ian King <colin.king@canonical.com>
Mon, 24 Jun 2019 16:39:59 +0000 (09:39 -0700)
committerThomas Hellstrom <thellstrom@vmware.com>
Thu, 8 Aug 2019 09:22:54 +0000 (11:22 +0200)
commit06d283121dac4a0253d554f7c694b703e18490b1
tree2d1c63d57abcf7ae63b81a4a5b08024cda989993
parente7256ed8a88e4c9250b1486f9214a43bcb6aab1a
drm/vmwgfx: fix memory leak when too many retries have occurred

Currently when too many retries have occurred there is a memory
leak on the allocation for reply on the error return path. Fix
this by kfree'ing reply before returning.

Addresses-Coverity: ("Resource leak")
Fixes: b3beb3761383 ("drm/vmwgfx: Add a check to handle host message failure")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Reviewed-by: Deepak Rawat <drawat@vmware.com>
Signed-off-by: Deepak Rawat <drawat@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
drivers/gpu/drm/vmwgfx/vmwgfx_msg.c