<HTML><HEAD><TITLE>Samsung Enterprise Portal mySingle</TITLE>
<META content=IE=5 http-equiv=X-UA-Compatible>
<META content="text/html; charset=windows-1252" http-equiv=Content-Type>
<STYLE id=mysingle_style type=text/css>P {
        MARGIN-BOTTOM: 5px; FONT-SIZE: 9pt; FONT-FAMILY: Arial, arial; MARGIN-TOP: 5px
}
TD {
        MARGIN-BOTTOM: 5px; FONT-SIZE: 9pt; FONT-FAMILY: Arial, arial; MARGIN-TOP: 5px
}
LI {
        MARGIN-BOTTOM: 5px; FONT-SIZE: 9pt; FONT-FAMILY: Arial, arial; MARGIN-TOP: 5px
}
BODY {
        FONT-SIZE: 9pt; FONT-FAMILY: Arial, arial; MARGIN: 10px; LINE-HEIGHT: 1.4
}
</STYLE>

<META name=GENERATOR content=ActiveSquare></HEAD>
<BODY>
<P>Sorry for wrong Subject message resending the corrected one</P>
<P> </P>
<P>------- <B>Original Message</B> -------</P>
<P><B>Sender</B> : Kabeer Ahmed Khan<kabeer.khan@samsung.com> Senior Software Engineer/SRI-Bangalore-Recruitment/Samsung Electronics</P>
<P><B>Date</B> : Oct 20, 2014 11:49 (GMT+05:30)</P>
<P><B>Title</B> : [PATCH weston v6 2/2 1/2] window : compare version and call appropriate destructor</P>
<P> </P>From: kabeer khan <KABEER.KHAN@SAMSUNG.COM><BR><BR>Signed-off-by: kabeer khan <KABEER.KHAN@SAMSUNG.COM><BR>---<BR>clients/window.c | 15 ++++++++++-----<BR>1 file changed, 10 insertions(+), 5 deletions(-)<BR><BR>diff --git a/clients/window.c b/clients/window.c<BR>index 139c7f9..c8ed9a2 100644<BR>--- a/clients/window.c<BR>+++ b/clients/window.c<BR>@@ -133,6 +133,7 @@ struct display {<BR><BR>int has_rgb565;<BR>int seat_version;<BR>+ int data_device_manager_version;<BR>};<BR><BR>struct window_output {<BR>@@ -5148,9 +5149,12 @@ input_destroy(struct input *input)<BR>if (input->selection_offer)<BR>data_offer_destroy(input->selection_offer);<BR><BR>- if (input->data_device)<BR>- wl_data_device_destroy(input->data_device);<BR>-<BR>+ if (input->data_device) {<BR>+ if(input->display->data_device_manager_version >= 2)<BR>+ wl_data_device_release(input->data_device);<BR>+ else<BR>+ wl_data_device_destroy(input->data_device);<BR>+ }<BR>if (input->display->seat_version >= 3) {<BR>if (input->pointer)<BR>wl_pointer_release(input->pointer);<BR>@@ -5234,9 +5238,10 @@ registry_handle_global(void *data, struct wl_registry *registry, uint32_t id,<BR>d->shm = wl_registry_bind(registry, id, &wl_shm_interface, 1);<BR>wl_shm_add_listener(d->shm, &shm_listener, d);<BR>} else if (strcmp(interface, "wl_data_device_manager") == 0) {<BR>+ d->data_device_manager_version = MIN(version, 2);<BR>d->data_device_manager =<BR>- wl_registry_bind(registry, id,<BR>- &wl_data_device_manager_interface, 1);<BR>+ wl_registry_bind(registry, id, <BR>+ &wl_data_device_manager_interface, d->data_device_manager_version);<BR>} else if (strcmp(interface, "xdg_shell") == 0) {<BR>d->xdg_shell = wl_registry_bind(registry, id,<BR>&xdg_shell_interface, 1);<BR>-- <BR>2.1.0<BR><BR>
<P> </P><!--SP:kabeer.khan--><!--kabeer.khan:EP-->
<P> </P>
<TABLE id=confidentialsignimg>
<TBODY>
<TR>
<TD NAMO_LOCK>
<P><IMG border=0 src="cid:XOK0LK7CT9SZ@namo.co.kr"></P></TD></TR></TBODY></TABLE></BODY></HTML><img src='http://ext.samsung.net/mailcheck/SeenTimeChecker?do=14f7afe1216e9674e0cf8bea7a3df23c5234d454aba63230ee60ab6642a0204c68faa76fc6d0059275e86b19dccefbe8abdf0e51799c0dfb021b7a989945d95349e5ff3dfdc8681d76f80bf81d31c863cf878f9a26ce15a0' border=0 width=0 height=0 style='display:none'>