projects
/
profile
/
ivi
/
weston.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1275859
)
compositor-drm: Don't try and scan out a SHM buffer directly
author
Rob Bradford
<rob@linux.intel.com>
Fri, 14 Sep 2012 22:02:47 +0000
(23:02 +0100)
committer
Rob Bradford
<rob@linux.intel.com>
Thu, 6 Dec 2012 18:57:44 +0000
(18:57 +0000)
gbm_bo_import will fail to produce a valid bo since the buffer is an SHM
buffer. This cause a crash when the NULL bo returned by gbm_bo_import is
dereferenced later.
Signed-off-by: Rob Bradford <rob@linux.intel.com>
src/compositor-drm.c
patch
|
blob
|
history
diff --git
a/src/compositor-drm.c
b/src/compositor-drm.c
index
1fa822a
..
4c56454
100644
(file)
--- a/
src/compositor-drm.c
+++ b/
src/compositor-drm.c
@@
-318,6
+318,9
@@
drm_output_prepare_scanout_surface(struct weston_output *_output,
es->buffer == NULL)
return NULL;
+ if (wl_buffer_is_shm(es->buffer))
+ return NULL;
+
bo = gbm_bo_import(c->gbm, GBM_BO_IMPORT_WL_BUFFER,
es->buffer, GBM_BO_USE_SCANOUT);