Loading ChangeLog +2 −0 Original line number Diff line number Diff line Loading @@ -102,6 +102,8 @@ Changes in version 0.2.0.20-?? - 2008-02-?? the TLS shutdown handshake is hardly unexpected. - Send NAMESERVER_STATUS messages for a single failed nameserver correctly. - Make Unix controlsockets work correctly on OpenBSD. Patch from tup. Bugfix on 0.2.0.3-alpha. o Code simplifications and refactoring: - Remove the tor_strpartition function: its logic was confused, Loading src/or/connection.c +3 −5 Original line number Diff line number Diff line Loading @@ -748,6 +748,7 @@ static connection_t * connection_create_listener(struct sockaddr *listensockaddr, int type, char* address) { /*XXXX021 this function should take a socklen too. */ connection_t *conn; int s; /* the socket we're going to make */ uint16_t usePort = 0; Loading Loading @@ -814,7 +815,6 @@ connection_create_listener(struct sockaddr *listensockaddr, int type, } #ifdef HAVE_SYS_UN_H } else if (listensockaddr->sa_family == AF_UNIX) { size_t len; start_reading = 1; /* For now only control ports can be unix domain sockets Loading @@ -835,9 +835,7 @@ connection_create_listener(struct sockaddr *listensockaddr, int type, goto err; } len = strlen(((struct sockaddr_un *)listensockaddr)->sun_path) + sizeof(((struct sockaddr_un *)listensockaddr)->sun_family); if (bind(s, listensockaddr, (socklen_t)len) == -1) { if (bind(s, listensockaddr, (socklen_t)sizeof(struct sockaddr_un)) == -1) { log_warn(LD_NET,"Bind to %s failed: %s.", address, tor_socket_strerror(tor_socket_errno(s))); goto err; Loading Loading
ChangeLog +2 −0 Original line number Diff line number Diff line Loading @@ -102,6 +102,8 @@ Changes in version 0.2.0.20-?? - 2008-02-?? the TLS shutdown handshake is hardly unexpected. - Send NAMESERVER_STATUS messages for a single failed nameserver correctly. - Make Unix controlsockets work correctly on OpenBSD. Patch from tup. Bugfix on 0.2.0.3-alpha. o Code simplifications and refactoring: - Remove the tor_strpartition function: its logic was confused, Loading
src/or/connection.c +3 −5 Original line number Diff line number Diff line Loading @@ -748,6 +748,7 @@ static connection_t * connection_create_listener(struct sockaddr *listensockaddr, int type, char* address) { /*XXXX021 this function should take a socklen too. */ connection_t *conn; int s; /* the socket we're going to make */ uint16_t usePort = 0; Loading Loading @@ -814,7 +815,6 @@ connection_create_listener(struct sockaddr *listensockaddr, int type, } #ifdef HAVE_SYS_UN_H } else if (listensockaddr->sa_family == AF_UNIX) { size_t len; start_reading = 1; /* For now only control ports can be unix domain sockets Loading @@ -835,9 +835,7 @@ connection_create_listener(struct sockaddr *listensockaddr, int type, goto err; } len = strlen(((struct sockaddr_un *)listensockaddr)->sun_path) + sizeof(((struct sockaddr_un *)listensockaddr)->sun_family); if (bind(s, listensockaddr, (socklen_t)len) == -1) { if (bind(s, listensockaddr, (socklen_t)sizeof(struct sockaddr_un)) == -1) { log_warn(LD_NET,"Bind to %s failed: %s.", address, tor_socket_strerror(tor_socket_errno(s))); goto err; Loading