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

[or-cvs] Fix bug in redirectstream.



Update of /home/or/cvsroot/tor/src/or
In directory moria.mit.edu:/tmp/cvs-serv28736/src/or

Modified Files:
	control.c 
Log Message:
Fix bug in redirectstream.

Index: control.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/or/control.c,v
retrieving revision 1.70
retrieving revision 1.71
diff -u -d -r1.70 -r1.71
--- control.c	27 Mar 2005 06:37:56 -0000	1.70
+++ control.c	31 Mar 2005 06:06:02 -0000	1.71
@@ -777,7 +777,7 @@
   connection_t *ap_conn;
   uint32_t conn_id;
   if (len < 6) {
-    send_control_error(conn, ERR_SYNTAX, "attachstream message too short");
+    send_control_error(conn, ERR_SYNTAX, "redirectstream message too short");
     return 0;
   }
   conn_id = ntohl(get_uint32(body));
@@ -789,7 +789,7 @@
                        "No AP connection found with given ID");
     return 0;
   }
-  strlcpy(ap_conn->socks_request->address, body+1,
+  strlcpy(ap_conn->socks_request->address, body+4,
           sizeof(ap_conn->socks_request->address));
 
   send_control_done(conn);