Refactor circuit_pick_create_handshake

Make the structure of circuit_pick_create_handshake consistent with
circuit_pick_extend_handshake.

No behaviour change.
This commit is contained in:
teor 2016-10-31 17:01:33 +11:00
parent 26d7a07ad7
commit d81f2b5d81
No known key found for this signature in database
GPG Key ID: 450CBA7F968F094B

View File

@ -829,12 +829,12 @@ circuit_pick_create_handshake(uint8_t *cell_type_out,
if (extend_info_supports_ntor(ei)) { if (extend_info_supports_ntor(ei)) {
*cell_type_out = CELL_CREATE2; *cell_type_out = CELL_CREATE2;
*handshake_type_out = ONION_HANDSHAKE_TYPE_NTOR; *handshake_type_out = ONION_HANDSHAKE_TYPE_NTOR;
return; } else {
} /* XXXX030 Remove support for deciding to use TAP and EXTEND. */
*cell_type_out = CELL_CREATE; *cell_type_out = CELL_CREATE;
*handshake_type_out = ONION_HANDSHAKE_TYPE_TAP; *handshake_type_out = ONION_HANDSHAKE_TYPE_TAP;
} }
}
/** Decide whether to use a TAP or ntor handshake for extending to <b>ei</b> /** Decide whether to use a TAP or ntor handshake for extending to <b>ei</b>
* and set *<b>handshake_type_out</b> accordingly. Decide whether we should * and set *<b>handshake_type_out</b> accordingly. Decide whether we should