Revert "Fix issue of compositor surface create passing wrong parameter to"

This reverts commit 67170f40a1.

this was changed intentionally to use the resource pointer in order to fix an
issue where external clients would reuse the same surface id,
thereby breaking the compositor with duplicate entries in the pixmap hash.

note, however, that internal windows in wayland DO use an int type pixmap id.
this is easily detected by checking the pid of the client for a window before doing
checks. this is necessary in order to be able to flag internal clients as internal
while still being able to match them with their surface id

also, uintptr_t is NOT indicative of an int type being used, it's an
int type which has the same size as a pointer, allowing casts between ints
and pointer.
This commit is contained in:
Mike Blumenkrantz 2016-01-19 12:11:27 -05:00
parent fbe959cccc
commit 092c834c5e
1 changed files with 1 additions and 1 deletions

View File

@ -1480,7 +1480,7 @@ _e_comp_wl_compositor_cb_surface_create(struct wl_client *client, struct wl_reso
E_Pixmap *ep;
/* try to create new pixmap */
if (!(ep = e_pixmap_new(E_PIXMAP_TYPE_WL, (uintptr_t)id)))
if (!(ep = e_pixmap_new(E_PIXMAP_TYPE_WL, res)))
{
ERR("Could not create new pixmap");
wl_resource_destroy(res);