mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Fix bug in redirectstream.
svn:r3926
This commit is contained in:
+2
-2
@@ -777,7 +777,7 @@ handle_control_redirectstream(connection_t *conn, uint32_t len,
|
||||
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 @@ handle_control_redirectstream(connection_t *conn, uint32_t len,
|
||||
"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);
|
||||
|
||||
Reference in New Issue
Block a user