From 249ae98e0f07aa375430ac2fba1b3bd0958edd41 Mon Sep 17 00:00:00 2001 From: Victor Berger Date: Sun, 1 Oct 2017 19:12:38 +0200 Subject: [PATCH] Fix invalid drop in SHM doc test Allowing the display to be dropped this early destroys the whole wayland context before we start using it... bad idea. --- src/wayland/shm/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wayland/shm/mod.rs b/src/wayland/shm/mod.rs index 4a87663..c88f3f3 100644 --- a/src/wayland/shm/mod.rs +++ b/src/wayland/shm/mod.rs @@ -23,7 +23,7 @@ //! use wayland_server::protocol::wl_shm::Format; //! //! # fn main() { -//! # let (_, mut event_loop) = wayland_server::create_display(); +//! # let (display, mut event_loop) = wayland_server::create_display(); //! // Insert the ShmGlobal into your event loop //! // Here, we specify that Yuyv and C8 format are supported //! // additionnaly to the standart Argb8888 and Xrgb8888.