Commit 02ec2cdb authored by Roger Dingledine's avatar Roger Dingledine
Browse files

bugfix: we were writing to stderr even when it's closed


svn:r868
parent 2de4fc2b
...@@ -272,8 +272,7 @@ int connection_connect(connection_t *conn, char *address, uint32_t addr, uint16_ ...@@ -272,8 +272,7 @@ int connection_connect(connection_t *conn, char *address, uint32_t addr, uint16_
if(connect(s,(struct sockaddr *)&dest_addr,sizeof(dest_addr)) < 0) { if(connect(s,(struct sockaddr *)&dest_addr,sizeof(dest_addr)) < 0) {
if(!ERRNO_CONN_EINPROGRESS(errno)) { if(!ERRNO_CONN_EINPROGRESS(errno)) {
/* yuck. kill it. */ /* yuck. kill it. */
perror("connect"); log_fn(LOG_INFO,"Connect() to %s:%u failed: %s",address,port,strerror(errno));
log_fn(LOG_INFO,"Connect() to %s:%u failed.",address,port);
close(s); close(s);
return -1; return -1;
} else { } else {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment