[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/master] Fix for bug 7112 (spewing complaints from tor_addr_is_internal)



commit 898bd1ae8f1eeb880eaaeba2caa1cda435a1ac5b
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date:   Wed Oct 17 11:15:01 2012 -0400

    Fix for bug 7112 (spewing complaints from tor_addr_is_internal)
    
    In 4768c0efe3e9471cc367c3740d1a4ba0ab79626c (not in any released
    version of Tor), we removed a little block of code that set the addr
    field of an exit connection used in making a tunneled directory
    request.  Turns out that wasn't right.
---
 src/or/connection_edge.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/src/or/connection_edge.c b/src/or/connection_edge.c
index e7bc09a..53b57eb 100644
--- a/src/or/connection_edge.c
+++ b/src/or/connection_edge.c
@@ -3180,7 +3180,12 @@ connection_exit_begin_conn(cell_t *cell, circuit_t *circ)
   n_stream->on_circuit = circ;
 
   if (rh.command == RELAY_COMMAND_BEGIN_DIR) {
+    tor_addr_t tmp_addr;
     tor_assert(or_circ);
+    if (or_circ->p_chan &&
+        channel_get_addr_if_possible(or_circ->p_chan, &tmp_addr)) {
+      tor_addr_copy(&n_stream->base_.addr, &tmp_addr);
+    }
     return connection_exit_connect_dir(n_stream);
   }
 



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits