Permalink
Browse files

Connection::try_bind: Pass port argument 0 as a string

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
  • Loading branch information...
1 parent b39da20 commit 7c942e68363126647fe55682209533868b0918f1 @andersk andersk committed Jan 4, 2014
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/network/network.cc
View
@@ -286,7 +286,7 @@ bool Connection::try_bind( const char *addr, int port_low, int port_high )
hints.ai_family = AF_UNSPEC;
hints.ai_socktype = SOCK_DGRAM;
hints.ai_flags = AI_PASSIVE | AI_NUMERICHOST | AI_NUMERICSERV;
- AddrInfo ai( addr, 0, &hints );
+ AddrInfo ai( addr, "0", &hints );
Addr local_addr;
socklen_t local_addr_len = ai.res->ai_addrlen;

0 comments on commit 7c942e6

Please sign in to comment.