projects
/
platform
/
upstream
/
weston.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4c93c08
)
clipboard: don't crash if the source client does not send a mime type
author
Giulio Camuffo
<giuliocamuffo@gmail.com>
Thu, 30 Apr 2015 21:13:55 +0000
(
00:13
+0300)
committer
Daniel Stone
<daniels@collabora.com>
Fri, 1 May 2015 12:01:57 +0000
(13:01 +0100)
Reviewed-by: Daniel Stone <daniels@collabora.com>
src/clipboard.c
patch
|
blob
|
history
diff --git
a/src/clipboard.c
b/src/clipboard.c
index c1091a9c44faf978401dc8705c3fa128cc8ac726..994c30167b9e12f2419ac468f62da5b1acde681d 100644
(file)
--- a/
src/clipboard.c
+++ b/
src/clipboard.c
@@
-254,7
+254,7
@@
clipboard_set_selection(struct wl_listener *listener, void *data)
mime_types = source->mime_types.data;
- if (pipe2(p, O_CLOEXEC) == -1)
+ if (
!mime_types ||
pipe2(p, O_CLOEXEC) == -1)
return;
source->send(source, mime_types[0], p[1]);