Skip to content
  • Simon Ser's avatar
    server: add wl_global_set_user_data · 1907c6b8
    Simon Ser authored
    When implementing a workaround for [1], one needs to accept a global to be
    bound even though it has become stale.
    
    Often, a global's user data is free'd when the global needs to be destroyed.
    Being able to set the global's user data (e.g. to NULL) can help preventing a
    use-after-free.
    
    (The alternative is to make the compositor responsible for keeping track of
    stale user data objects via e.g. refcounting.)
    
    [1]: wayland/wayland#10
    
    
    
    Signed-off-by: Simon Ser's avatarSimon Ser <contact@emersion.fr>
    1907c6b8