#64 [patch] API for socket binding

API
closed
nobody
General (24)
5
2012-07-30
2012-07-05
Pugachev Maxim
No

This patch adds API for socket binding (for a latter use with listners or anything else).

Discussion

  • Pugachev Maxim
    Pugachev Maxim
    2012-07-05

    Patch for this issue

     
    Attachments
  • Pugachev Maxim
    Pugachev Maxim
    2012-07-05

    • summary: API for socket binding --> [patch] API for socket binding
     
  • Nick Mathewson
    Nick Mathewson
    2012-07-30

    • status: open --> closed
     
  • Nick Mathewson
    Nick Mathewson
    2012-07-30

    NAK, for many reasons:

    1) It doesn't let you specify a family, or any resolution rules.
    2) It doesn't let you specify the many flags you might want to provide when creating, resolving, or binding a socket.
    3) It pollutes the namespace with a new function that doesn't start with ev* or bev* or one of those.
    4) It blocks while resolution happens.

    Have a look at evconnlistener_new_bind() for more on the flags that are needed here, and at bufferevent_socket_connect() and evdns_getaddrinfo() for more on which additional flags would be needed.