diff options
author | Roger Dingledine <arma@torproject.org> | 2002-09-17 08:14:37 +0000 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2002-09-17 08:14:37 +0000 |
commit | 09daf01e4a0f2faed10cab14fec5f7d32dc3bd31 (patch) | |
tree | 8bcbd9ac0f4a844bfb6e91b85285abea405d837e /src/or/connection_ap.c | |
parent | 6cb8a91d5cbb1217a43119cc0e98b14d2c565d37 (diff) | |
download | tor-09daf01e4a0f2faed10cab14fec5f7d32dc3bd31.tar.gz tor-09daf01e4a0f2faed10cab14fec5f7d32dc3bd31.zip |
added 'connected' cell type
see http://archives.seul.org/or/dev/Sep-2002/msg00018.html
svn:r103
Diffstat (limited to 'src/or/connection_ap.c')
-rw-r--r-- | src/or/connection_ap.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/or/connection_ap.c b/src/or/connection_ap.c index 3080fe8226..732af7b067 100644 --- a/src/or/connection_ap.c +++ b/src/or/connection_ap.c @@ -253,7 +253,6 @@ int ap_handshake_send_onion(connection_t *ap_conn, connection_t *n_conn, circuit cell_t cell; int tmpbuflen, dataleft; char *tmpbuf; - char zero=0; circ->n_aci = get_unique_aci_by_addr_port(circ->n_addr, circ->n_port, ACI_TYPE_BOTH); circ->n_conn = n_conn; @@ -331,13 +330,18 @@ int ap_handshake_send_onion(connection_t *ap_conn, connection_t *n_conn, circuit /* FIXME should set circ->expire to something here */ - /* now we want to give the AP a "0" byte, because it wants to hear - * back from us */ - connection_write_to_buf(&zero, 1, ap_conn); /* this does connection_start_writing() too */ - return 0; } +int connection_ap_send_connected(connection_t *conn) { + char zero=0; + + assert(conn); + + /* give the AP a "0" byte, because it wants to hear that we've connected */ + return connection_write_to_buf(&zero, 1, conn); +} + int connection_ap_process_data_cell(cell_t *cell, connection_t *conn) { /* an incoming data cell has arrived */ |