amdgpu/dc: kfree already checks for NULL.

Don't bother checking for it.

Found with the cocci ifnullfree.cocci script.

Signed-off-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Dave Airlie
2017-10-03 14:27:14 +10:00
committed by Alex Deucher
parent 5667ff5c11
commit d029810caa
5 changed files with 9 additions and 22 deletions

View File

@@ -130,8 +130,7 @@ struct vector *dal_vector_create(
void dal_vector_destruct(
struct vector *vector)
{
if (vector->container != NULL)
kfree(vector->container);
kfree(vector->container);
vector->count = 0;
vector->capacity = 0;
}