By default the server will dump protocol for both the server and its
clients when run with WAYLAND_DEBUG=1. That's still the case, but it now
also understands WAYLAND_DEBUG=client or WAYLAND_DEBUG=server, which
will only enable debug dumping on either client or server side.
const char *debug;
debug = getenv("WAYLAND_DEBUG");
- if (debug)
+ if (debug && (strstr(debug, "client") || strstr(debug, "1")))
wl_debug = 1;
display = malloc(sizeof *display);
const char *debug;
debug = getenv("WAYLAND_DEBUG");
- if (debug)
+ if (debug && (strstr(debug, "server") || strstr(debug, "1")))
wl_debug = 1;
display = malloc(sizeof *display);