[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] When parsing foo.exit, if foo is unknown, and we are leavin...
Update of /home/or/cvsroot/tor/src/or
In directory moria:/tmp/cvs-serv31663/src/or
Modified Files:
connection_edge.c
Log Message:
When parsing foo.exit, if foo is unknown, and we are leaving circuits unattached, set the chosen_exit field and leave the address empty
Index: connection_edge.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/connection_edge.c,v
retrieving revision 1.367
retrieving revision 1.368
diff -u -d -r1.367 -r1.368
--- connection_edge.c 4 Dec 2005 23:06:48 -0000 1.367
+++ connection_edge.c 5 Dec 2005 04:38:21 -0000 1.368
@@ -1002,9 +1002,10 @@
}
} else {
struct in_addr in;
- routerinfo_t *r = router_get_by_nickname(socks->address, 1);
+ conn->chosen_exit_name = socks->address;
+ *socks->address = 0;
+ routerinfo_t *r = router_get_by_nickname(conn->chosen_exit_name, 1);
if (r) {
- conn->chosen_exit_name = tor_strdup(socks->address);
/* XXXX Should this use server->address instead? */
in.s_addr = htonl(r->addr);
strlcpy(socks->address, inet_ntoa(in), sizeof(socks->address));