[PATCH wayland v3 04/10] connection: Clear fds we shouldn't close to -1

Daniel Stone daniel at fooishbar.org
Wed Dec 27 14:12:56 UTC 2017


Hi Derek,

On 6 December 2017 at 17:22, Derek Foreman <derekf at osg.samsung.com> wrote:
> This initializes all the fd arguments in closures to -1 and clears
> them back to -1 when they've been dispatched or serialized.
>
> This means that any valid fd in a closure is currently libwayland's
> responsibility to close in the case of an error.

As with the previous, I'm totally happy with this and intend to land,
but a good follow-on might be to have wl_closure_{invoke,dispatch}
take full ownership of the closure, i.e. unconditionally destroy it
before return. All its users do this anyway.

Cheers,
Daniel


More information about the wayland-devel mailing list