Skip to content

socket closed after UnixStream::into_raw_fd() #147

Closed

Description

@yshui

UnixStream holds a IoHandle<mio_uds::UnixStream> which is not correctly disposed of in into_raw_fd, resulting in the returned file descriptor being closed when into_raw_fd returns, making the function useless.

Activity

  1. yshui commented on Sep 5, 2019

    @yshui
    ContributorAuthor

    I think the best way is to
    impl<T: IntoRawFd> IntoRawFd for IoHandle<T> and use that, instead of keeping a copy of the RawFd.

  2. added a commit that references this issue on Sep 8, 2019
    7c05356
  3. yshui commented on Aug 18, 2020

    @yshui
    ContributorAuthor

    This bug is reintroduced..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions