Skip to content
Commit aad1e190 authored by Pekka Paalanen's avatar Pekka Paalanen Committed by Kristian Høgsberg
Browse files

server: destroy the socket event source on display destroy



On wl_display_add_socket(), the listening socket fd is added to the
event loop. However, wl_event_source object is not stored and hence
cannot be freed, resulting in a minor leak.

Store wl_event_source pointer in struct wl_socket so we can track it,
and destroy it on wl_display_destroy(). The event loop itself must be
destroyed after destroying the event sources linked to it.

Fixes a Valgrind reported memory leak.

Signed-off-by: default avatarPekka Paalanen <ppaalanen@gmail.com>
parent 1f58d155
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment