Re: [PATCH] drm: vc4: remove redundant check of plane being non-null

2017-03-17 Thread Eric Anholt
Colin King writes: > From: Colin Ian King > > The pointer plane is always null on the error path at label 'fail' > hence the check if it is non-null is redundant. We can therefore > remove the check and the destruction of plane as well as the fail > error path and instead just return an -ENOMEM

[PATCH] drm: vc4: remove redundant check of plane being non-null

2017-03-16 Thread Colin King
From: Colin Ian King The pointer plane is always null on the error path at label 'fail' hence the check if it is non-null is redundant. We can therefore remove the check and the destruction of plane as well as the fail error path and instead just return an -ENOMEM ERR_PTR. Detected by CoveritySc