Automatically select the wayland backend if WAYLAND_SOCKET is set
authorJason Ekstrand <jason@jlekstrand.net>
Thu, 3 Apr 2014 00:53:56 +0000 (19:53 -0500)
committerKristian Høgsberg <krh@bitplanet.net>
Thu, 3 Apr 2014 04:27:06 +0000 (21:27 -0700)
Signed-off-by: Jason Ekstrand <jason@jlekstrand.net>
src/compositor.c

index 6b90bd8..362e959 100644 (file)
@@ -4168,7 +4168,7 @@ int main(int argc, char *argv[])
                                                 NULL);
 
        if (!backend) {
-               if (getenv("WAYLAND_DISPLAY"))
+               if (getenv("WAYLAND_DISPLAY") || getenv("WAYLAND_SOCKET"))
                        backend = strdup("wayland-backend.so");
                else if (getenv("DISPLAY"))
                        backend = strdup("x11-backend.so");