summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVíctor Manuel Jáquez Leal <vjaquez@igalia.com>2017-08-08 17:12:06 +0200
committerVíctor Manuel Jáquez Leal <vjaquez@igalia.com>2017-08-24 13:04:22 +0200
commitc1854ec3645f6d46d47f58bb995d9d982e077c4b (patch)
tree51920c4db2984d85794e015960579eb6d9b42a7b
parent1d83bf01c6f1d2e732bec370ae8401c6a751f40b (diff)
libs: vaapi: object: remove unrequired NULL check
Coverity scan bug: Dereference after null check: Either the check against null is unnecessary, or there may be a null pointer dereference. Variable klass has been validated as non-NULL several time before in gst_vaapi_object_new() function, so there is no need to check it again.
-rw-r--r--gst-libs/gst/vaapi/gstvaapiobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gst-libs/gst/vaapi/gstvaapiobject.c b/gst-libs/gst/vaapi/gstvaapiobject.c
index 15af2679..8609ef77 100644
--- a/gst-libs/gst/vaapi/gstvaapiobject.c
+++ b/gst-libs/gst/vaapi/gstvaapiobject.c
@@ -98,7 +98,7 @@ gst_vaapi_object_new (const GstVaapiObjectClass * klass,
if (sub_size > 0)
memset (((guchar *) object) + sizeof (*object), 0, sub_size);
- if (klass && klass->init)
+ if (klass->init)
klass->init (object);
return object;
}