projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
74470ba
)
etnaviv: fix a null pointer dereference
author
Andrii Simiklit
<andrii.simiklit@globallogic.com>
Fri, 19 Jul 2019 14:39:07 +0000
(17:39 +0300)
committer
Lucas Stach
<l.stach@pengutronix.de>
Mon, 5 Aug 2019 13:31:43 +0000
(15:31 +0200)
This issue was found by cppcheck
Signed-off-by: Andrii Simiklit <andrii.simiklit@globallogic.com>
Reviewed-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
src/etnaviv/drm/etnaviv_bo.c
patch
|
blob
|
history
diff --git
a/src/etnaviv/drm/etnaviv_bo.c
b/src/etnaviv/drm/etnaviv_bo.c
index 6e952fa478582bc58b3faf00214dfdbc00489bec..2b1fbbbc3c7f86fc66cc63b219cd878fb2c1a282 100644
(file)
--- a/
src/etnaviv/drm/etnaviv_bo.c
+++ b/
src/etnaviv/drm/etnaviv_bo.c
@@
-238,11
+238,11
@@
out_unlock:
/* destroy a buffer object */
void etna_bo_del(struct etna_bo *bo)
{
- struct etna_device *dev = bo->dev;
-
if (!bo)
return;
+ struct etna_device *dev = bo->dev;
+
if (!p_atomic_dec_zero(&bo->refcnt))
return;