summaryrefslogtreecommitdiff
path: root/src/or/connection_edge.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2014-04-02 13:38:50 -0400
committerNick Mathewson <nickm@torproject.org>2014-04-02 15:38:00 -0400
commitda908a593fded0c4774c6cdfb6b5e51c87f65d88 (patch)
tree4bce2b353cc03c648403170b213e84b573864f37 /src/or/connection_edge.c
parent4215c801ffc11f19949be3da2d46158664f0bf97 (diff)
downloadtor-da908a593fded0c4774c6cdfb6b5e51c87f65d88.tar.gz
tor-da908a593fded0c4774c6cdfb6b5e51c87f65d88.zip
Unit tests for connection_edge_process_resolved_cell
Also rename a function to be more accurate (resolve->resolved)
Diffstat (limited to 'src/or/connection_edge.c')
-rw-r--r--src/or/connection_edge.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/or/connection_edge.c b/src/or/connection_edge.c
index 1ecc553e56..41ca6119b0 100644
--- a/src/or/connection_edge.c
+++ b/src/or/connection_edge.c
@@ -67,9 +67,9 @@ static int connection_ap_supports_optimistic_data(const entry_connection_t *);
* a socks reply, send one now (based on endreason). Also set
* has_sent_end to 1, and mark the conn.
*/
-void
-connection_mark_unattached_ap_(entry_connection_t *conn, int endreason,
- int line, const char *file)
+MOCK_IMPL(void,
+connection_mark_unattached_ap_,(entry_connection_t *conn, int endreason,
+ int line, const char *file))
{
connection_t *base_conn = ENTRY_TO_CONN(conn);
edge_connection_t *edge_conn = ENTRY_TO_EDGE_CONN(conn);
@@ -2093,13 +2093,13 @@ connection_ap_handshake_socks_resolved_addr(entry_connection_t *conn,
**/
/* XXXX the use of the ttl and expires fields is nutty. Let's make this
* interface and those that use it less ugly. */
-void
-connection_ap_handshake_socks_resolved(entry_connection_t *conn,
+MOCK_IMPL(void,
+connection_ap_handshake_socks_resolved,(entry_connection_t *conn,
int answer_type,
size_t answer_len,
const uint8_t *answer,
int ttl,
- time_t expires)
+ time_t expires))
{
char buf[384];
size_t replylen;