lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Thu, 18 May 2017 14:39:42 +0100 From: Colin King <colin.king@...onical.com> To: Daniel Vetter <daniel.vetter@...el.com>, Jani Nikula <jani.nikula@...ux.intel.com>, David Airlie <airlied@...ux.ie>, Mika Kuoppala <mika.kuoppala@...el.com>, Chris Wilson <chris@...is-wilson.co.uk>, intel-gfx@...ts.freedesktop.org, dri-devel@...ts.freedesktop.org Cc: kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org Subject: [PATCH] drm/i915: Check C for null pointer rather than B From: Colin Ian King <colin.king@...onical.com> There are two occasions where pointer B is being check for a NULL when it should be pointer C instead. Fix these. Detected by CoverityScan, CID#1436348,1436349 ("Logically Dead Code") Fixes: 47624cc3301b60 ("drm/i915: Import the kfence selftests for i915_sw_fence") Signed-off-by: Colin Ian King <colin.king@...onical.com> --- drivers/gpu/drm/i915/selftests/i915_sw_fence.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/selftests/i915_sw_fence.c b/drivers/gpu/drm/i915/selftests/i915_sw_fence.c index 98baf10c28c6..c31d439fae3a 100644 --- a/drivers/gpu/drm/i915/selftests/i915_sw_fence.c +++ b/drivers/gpu/drm/i915/selftests/i915_sw_fence.c @@ -311,7 +311,7 @@ static int test_AB_C(void *arg) } C = alloc_fence(); - if (!B) { + if (!C) { ret = -ENOMEM; goto err_B; } @@ -388,7 +388,7 @@ static int test_C_AB(void *arg) } C = alloc_fence(); - if (!B) { + if (!C) { ret = -ENOMEM; goto err_B; } -- 2.11.0
Powered by blists - more mailing lists