xwm: Fix fd leak in weston_wm_send_data()

The call to source->send(source, mime_type, p[1]); dups the fd, and we have
to close p[1] to not leak it.
This commit is contained in:
Kristian Høgsberg 2013-09-04 22:32:50 -07:00
parent 3f7fcf83f6
commit 73bdc0ce85

View File

@ -447,6 +447,7 @@ weston_wm_send_data(struct weston_wm *wm, xcb_atom_t target, const char *mime_ty
source = seat->selection_data_source;
source->send(source, mime_type, p[1]);
close(p[1]);
}
static void