Skip to content
Commit cf19fa2c authored by Noralf Trønnes's avatar Noralf Trønnes
Browse files

drm/client: Fix double free in error path



This fixes a static checker warning:

	drivers/gpu/drm/drm_client.c:289 drm_client_buffer_create()
	error: double free of 'buffer'

Extend drm_client_buffer_delete() to handle the case when there's no
dumb buffer attached and drop the extra kfree.

Fixes: c76f0f7c ("drm: Begin an API for in-kernel clients")
Reported-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: default avatarNoralf Trønnes <noralf@tronnes.org>
Reviewed-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20180712150414.46908-1-noralf@tronnes.org
parent a08eac47
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment