]> granicus.if.org Git - libevent/commit
Revert "Fix potential fd leak in listener_read_cb()"
authorAzat Khuzhin <a3at.mail@gmail.com>
Tue, 5 Dec 2017 19:59:20 +0000 (22:59 +0300)
committerAzat Khuzhin <a3at.mail@gmail.com>
Sun, 10 Dec 2017 20:55:51 +0000 (23:55 +0300)
commit94eae336a2f8933741b5984c61616abae9b5ed8c
treedd30ea98a13918b199be4ea17fc6dd696f3f123d
parent6ee73ea9b0b15a9f4909c51e171b7799210ec26c
Revert "Fix potential fd leak in listener_read_cb()"

This reverts commit a695a720cda892c270736d127333d73553842094.

@kgraefe:
  "I believe that this commit is just wrong: if lev->cnt is not 1 after
  the callback, new_fd will still never be closed in listener_read_cb().
  So in that case it is the responsibility of the user's code to close
  the file descriptor (which is fine). But why shouldn't it be in the
  other case? And how does the user's code know?"

And I agree
listener.c