1
0
Fork 0

wayland: Use wl_display_add_socket_auto

This commit is contained in:
Jasper St. Pierre 2014-08-05 16:10:17 -04:00
parent 97f4eb6b75
commit 2ce23072d3
2 changed files with 3 additions and 3 deletions

View file

@ -70,7 +70,7 @@ typedef struct
struct _MetaWaylandCompositor
{
struct wl_display *wayland_display;
char *display_name;
const char *display_name;
ClutterActor *stage;
GHashTable *outputs;
struct wl_list frame_callbacks;

View file

@ -417,8 +417,8 @@ meta_wayland_init (void)
meta_wayland_seat_init (compositor);
/* FIXME: find the first free name instead */
compositor->display_name = g_strdup ("wayland-0");
if (wl_display_add_socket (compositor->wayland_display, compositor->display_name))
compositor->display_name = wl_display_add_socket_auto (compositor->wayland_display);
if (compositor->display_name == NULL)
g_error ("Failed to create socket");
/* XXX: It's important that we only try and start xwayland after we