vlc | branch: master | Alexandre Janniaux <[email protected]> | Mon Oct 28 14:21:24 2019 +0100| [5307e228aae70a34091f636b0331278981be52e8] | committer: Thomas Guillem
wayland: shm: fix uninitialized variable before use In case of error, the registry variable is clobbered by the goto from error handling and is freed without a correct value. Signed-off-by: Thomas Guillem <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=5307e228aae70a34091f636b0331278981be52e8 --- modules/video_output/wayland/shm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/video_output/wayland/shm.c b/modules/video_output/wayland/shm.c index 9e22ff549f..77acabdd0c 100644 --- a/modules/video_output/wayland/shm.c +++ b/modules/video_output/wayland/shm.c @@ -287,13 +287,13 @@ static int Open(vout_display_t *vd, const vout_display_cfg_t *cfg, assert(sys->embed != NULL); struct wl_display *display = sys->embed->display.wl; + struct vlc_wl_registry *registry = NULL; sys->eventq = wl_display_create_queue(display); if (sys->eventq == NULL) goto error; - struct vlc_wl_registry *registry = vlc_wl_registry_get(display, - sys->eventq); + registry = vlc_wl_registry_get(display, sys->eventq); if (registry == NULL) goto error; _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
