Skip to content
  • Daniel Stone's avatar
    client: Use refcount exclusively for destruction · b39d8933
    Daniel Stone authored
    Commit e273c7cd
    
     added a refcount to wl_proxy. The refcount is set to 1
    on creation, decreased when the client explicitly destroys the proxy,
    and is increased and decreased every time an event referencing that
    proxy is queued.
    
    Assuming no bugs, this means the refcount cannot reach 0 without the
    proxy being explicitly destroyed. However, some (not all) of the
    proxy-unref paths were only destroying the proxy if it had already been
    deleted. This should already be enforced by refcounting, so remove the
    check and rely solely on the refcount as the arbiter of when to free a
    proxy.
    
    Signed-off-by: default avatarDaniel Stone <daniels@collabora.com>
    Reviewed-by: default avatarDerek Foreman <derekf@osg.samsung.com>
    Cc: Jonas Ådahl <jadahl@gmail.com>
    b39d8933