提交 ec530829 编写于 作者: M Markus Elfring 提交者: Daniel Vetter

GPU-DRM: Delete an unnecessary check before drm_property_unreference_blob()

The drm_property_unreference_blob() function tests whether its argument
is NULL and then returns immediately.
Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.
Signed-off-by: NMarkus Elfring <elfring@users.sourceforge.net>
Reviewed-by: NZhao Junwang <zhjwpku@gmail.com>
Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
上级 a3d1d001
...@@ -4469,9 +4469,7 @@ static int drm_property_replace_global_blob(struct drm_device *dev, ...@@ -4469,9 +4469,7 @@ static int drm_property_replace_global_blob(struct drm_device *dev,
goto err_created; goto err_created;
} }
if (old_blob) drm_property_unreference_blob(old_blob);
drm_property_unreference_blob(old_blob);
*replace = new_blob; *replace = new_blob;
return 0; return 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册