Replace accumulated C ;;s with ;s

I don't know where these came from.
This commit is contained in:
Nick Mathewson 2017-09-15 16:43:17 -04:00
parent 76c33f7ff4
commit f4af1919ab
10 changed files with 33 additions and 33 deletions

View File

@ -213,7 +213,7 @@ addressmap_clear_excluded_trackexithosts(const or_options_t *options)
while (dot > target && *dot != '.') while (dot > target && *dot != '.')
dot--; dot--;
if (*dot == '.') dot++; if (*dot == '.') dot++;
nodename = tor_strndup(dot, len-5-(dot-target));; nodename = tor_strndup(dot, len-5-(dot-target));
node = node_get_by_nickname(nodename, NNF_NO_WARN_UNNAMED); node = node_get_by_nickname(nodename, NNF_NO_WARN_UNNAMED);
tor_free(nodename); tor_free(nodename);
if (!node || if (!node ||

View File

@ -3485,7 +3485,7 @@ options_validate(or_options_t *old_options, or_options_t *options,
if (options->RendPostPeriod < min_rendpostperiod) { if (options->RendPostPeriod < min_rendpostperiod) {
log_warn(LD_CONFIG, "RendPostPeriod option is too short; " log_warn(LD_CONFIG, "RendPostPeriod option is too short; "
"raising to %d seconds.", min_rendpostperiod); "raising to %d seconds.", min_rendpostperiod);
options->RendPostPeriod = min_rendpostperiod;; options->RendPostPeriod = min_rendpostperiod;
} }
if (options->RendPostPeriod > MAX_DIR_PERIOD) { if (options->RendPostPeriod > MAX_DIR_PERIOD) {

View File

@ -5846,7 +5846,7 @@ control_event_circuit_cell_stats(void)
if (!get_options()->TestingEnableCellStatsEvent || if (!get_options()->TestingEnableCellStatsEvent ||
!EVENT_IS_INTERESTING(EVENT_CELL_STATS)) !EVENT_IS_INTERESTING(EVENT_CELL_STATS))
return 0; return 0;
cell_stats = tor_malloc(sizeof(cell_stats_t));; cell_stats = tor_malloc(sizeof(cell_stats_t));
SMARTLIST_FOREACH_BEGIN(circuit_get_global_list(), circuit_t *, circ) { SMARTLIST_FOREACH_BEGIN(circuit_get_global_list(), circuit_t *, circ) {
if (!circ->testing_cell_stats) if (!circ->testing_cell_stats)
continue; continue;

View File

@ -2306,7 +2306,7 @@ routerlist_add_node_and_family(smartlist_t *sl, const routerinfo_t *router)
{ {
/* XXXX MOVE ? */ /* XXXX MOVE ? */
node_t fake_node; node_t fake_node;
const node_t *node = node_get_by_id(router->cache_info.identity_digest);; const node_t *node = node_get_by_id(router->cache_info.identity_digest);
if (node == NULL) { if (node == NULL) {
memset(&fake_node, 0, sizeof(fake_node)); memset(&fake_node, 0, sizeof(fake_node));
fake_node.ri = (routerinfo_t *)router; fake_node.ri = (routerinfo_t *)router;

View File

@ -3745,119 +3745,119 @@ test_config_port_cfg_line_extract_addrport(void *arg)
tt_int_op(port_cfg_line_extract_addrport("", &a, &unixy, &rest), OP_EQ, 0); tt_int_op(port_cfg_line_extract_addrport("", &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 0); tt_int_op(unixy, OP_EQ, 0);
tt_str_op(a, OP_EQ, "");; tt_str_op(a, OP_EQ, "");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("hello", &a, &unixy, &rest), tt_int_op(port_cfg_line_extract_addrport("hello", &a, &unixy, &rest),
OP_EQ, 0); OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 0); tt_int_op(unixy, OP_EQ, 0);
tt_str_op(a, OP_EQ, "hello");; tt_str_op(a, OP_EQ, "hello");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport(" flipperwalt gersplut", tt_int_op(port_cfg_line_extract_addrport(" flipperwalt gersplut",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 0); tt_int_op(unixy, OP_EQ, 0);
tt_str_op(a, OP_EQ, "flipperwalt");; tt_str_op(a, OP_EQ, "flipperwalt");
tt_str_op(rest, OP_EQ, "gersplut"); tt_str_op(rest, OP_EQ, "gersplut");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport(" flipperwalt \t gersplut", tt_int_op(port_cfg_line_extract_addrport(" flipperwalt \t gersplut",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 0); tt_int_op(unixy, OP_EQ, 0);
tt_str_op(a, OP_EQ, "flipperwalt");; tt_str_op(a, OP_EQ, "flipperwalt");
tt_str_op(rest, OP_EQ, "gersplut"); tt_str_op(rest, OP_EQ, "gersplut");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("flipperwalt \t gersplut", tt_int_op(port_cfg_line_extract_addrport("flipperwalt \t gersplut",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 0); tt_int_op(unixy, OP_EQ, 0);
tt_str_op(a, OP_EQ, "flipperwalt");; tt_str_op(a, OP_EQ, "flipperwalt");
tt_str_op(rest, OP_EQ, "gersplut"); tt_str_op(rest, OP_EQ, "gersplut");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("unix:flipperwalt \t gersplut", tt_int_op(port_cfg_line_extract_addrport("unix:flipperwalt \t gersplut",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "flipperwalt");; tt_str_op(a, OP_EQ, "flipperwalt");
tt_str_op(rest, OP_EQ, "gersplut"); tt_str_op(rest, OP_EQ, "gersplut");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("lolol", tt_int_op(port_cfg_line_extract_addrport("lolol",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 0); tt_int_op(unixy, OP_EQ, 0);
tt_str_op(a, OP_EQ, "lolol");; tt_str_op(a, OP_EQ, "lolol");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("unix:lolol", tt_int_op(port_cfg_line_extract_addrport("unix:lolol",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "lolol");; tt_str_op(a, OP_EQ, "lolol");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("unix:lolol ", tt_int_op(port_cfg_line_extract_addrport("unix:lolol ",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "lolol");; tt_str_op(a, OP_EQ, "lolol");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport(" unix:lolol", tt_int_op(port_cfg_line_extract_addrport(" unix:lolol",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "lolol");; tt_str_op(a, OP_EQ, "lolol");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("foobar:lolol", tt_int_op(port_cfg_line_extract_addrport("foobar:lolol",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 0); tt_int_op(unixy, OP_EQ, 0);
tt_str_op(a, OP_EQ, "foobar:lolol");; tt_str_op(a, OP_EQ, "foobar:lolol");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport(":lolol", tt_int_op(port_cfg_line_extract_addrport(":lolol",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 0); tt_int_op(unixy, OP_EQ, 0);
tt_str_op(a, OP_EQ, ":lolol");; tt_str_op(a, OP_EQ, ":lolol");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("unix:\"lolol\"", tt_int_op(port_cfg_line_extract_addrport("unix:\"lolol\"",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "lolol");; tt_str_op(a, OP_EQ, "lolol");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("unix:\"lolol\" ", tt_int_op(port_cfg_line_extract_addrport("unix:\"lolol\" ",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "lolol");; tt_str_op(a, OP_EQ, "lolol");
tt_str_op(rest, OP_EQ, ""); tt_str_op(rest, OP_EQ, "");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("unix:\"lolol\" foo ", tt_int_op(port_cfg_line_extract_addrport("unix:\"lolol\" foo ",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "lolol");; tt_str_op(a, OP_EQ, "lolol");
tt_str_op(rest, OP_EQ, "foo "); tt_str_op(rest, OP_EQ, "foo ");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("unix:\"lol ol\" foo ", tt_int_op(port_cfg_line_extract_addrport("unix:\"lol ol\" foo ",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "lol ol");; tt_str_op(a, OP_EQ, "lol ol");
tt_str_op(rest, OP_EQ, "foo "); tt_str_op(rest, OP_EQ, "foo ");
tor_free(a); tor_free(a);
tt_int_op(port_cfg_line_extract_addrport("unix:\"lol\\\" ol\" foo ", tt_int_op(port_cfg_line_extract_addrport("unix:\"lol\\\" ol\" foo ",
&a, &unixy, &rest), OP_EQ, 0); &a, &unixy, &rest), OP_EQ, 0);
tt_int_op(unixy, OP_EQ, 1); tt_int_op(unixy, OP_EQ, 1);
tt_str_op(a, OP_EQ, "lol\" ol");; tt_str_op(a, OP_EQ, "lol\" ol");
tt_str_op(rest, OP_EQ, "foo "); tt_str_op(rest, OP_EQ, "foo ");
tor_free(a); tor_free(a);

View File

@ -870,7 +870,7 @@ test_dir_handle_get_server_descriptors_authority(void* data)
mock_routerinfo->cache_info.signed_descriptor_body = mock_routerinfo->cache_info.signed_descriptor_body =
tor_strdup(TEST_DESCRIPTOR); tor_strdup(TEST_DESCRIPTOR);
mock_routerinfo->cache_info.signed_descriptor_len = mock_routerinfo->cache_info.signed_descriptor_len =
strlen(TEST_DESCRIPTOR) - annotation_len;; strlen(TEST_DESCRIPTOR) - annotation_len;
mock_routerinfo->cache_info.annotations_len = annotation_len; mock_routerinfo->cache_info.annotations_len = annotation_len;
mock_routerinfo->cache_info.published_on = time(NULL); mock_routerinfo->cache_info.published_on = time(NULL);

View File

@ -1522,7 +1522,7 @@ test_entry_guard_retry_unreachable(void *arg)
entry_guards_expand_sample(gs); entry_guards_expand_sample(gs);
/* Let's say that we have two guards, and they're down. /* Let's say that we have two guards, and they're down.
*/ */
time_t start = approx_time();; time_t start = approx_time();
entry_guard_t *g1 = smartlist_get(gs->sampled_entry_guards, 0); entry_guard_t *g1 = smartlist_get(gs->sampled_entry_guards, 0);
entry_guard_t *g2 = smartlist_get(gs->sampled_entry_guards, 1); entry_guard_t *g2 = smartlist_get(gs->sampled_entry_guards, 1);
entry_guard_t *g3 = smartlist_get(gs->sampled_entry_guards, 2); entry_guard_t *g3 = smartlist_get(gs->sampled_entry_guards, 2);

View File

@ -170,7 +170,7 @@ test_establish_intro_wrong_purpose(void *arg)
ssize_t cell_len = 0; ssize_t cell_len = 0;
char circ_nonce[DIGEST_LEN] = {0}; char circ_nonce[DIGEST_LEN] = {0};
uint8_t cell_body[RELAY_PAYLOAD_SIZE]; uint8_t cell_body[RELAY_PAYLOAD_SIZE];
or_circuit_t *intro_circ = or_circuit_new(0,NULL);; or_circuit_t *intro_circ = or_circuit_new(0,NULL);
(void)arg; (void)arg;
@ -211,7 +211,7 @@ static void
test_establish_intro_wrong_keytype(void *arg) test_establish_intro_wrong_keytype(void *arg)
{ {
int retval; int retval;
or_circuit_t *intro_circ = or_circuit_new(0,NULL);; or_circuit_t *intro_circ = or_circuit_new(0,NULL);
char circ_nonce[DIGEST_LEN] = {0}; char circ_nonce[DIGEST_LEN] = {0};
(void) arg; (void) arg;
@ -239,7 +239,7 @@ test_establish_intro_wrong_keytype2(void *arg)
char circ_nonce[DIGEST_LEN] = {0}; char circ_nonce[DIGEST_LEN] = {0};
uint8_t cell_body[RELAY_PAYLOAD_SIZE]; uint8_t cell_body[RELAY_PAYLOAD_SIZE];
ssize_t cell_len = 0; ssize_t cell_len = 0;
or_circuit_t *intro_circ = or_circuit_new(0,NULL);; or_circuit_t *intro_circ = or_circuit_new(0,NULL);
(void) arg; (void) arg;
@ -275,7 +275,7 @@ test_establish_intro_wrong_mac(void *arg)
ssize_t cell_len = 0; ssize_t cell_len = 0;
uint8_t cell_body[RELAY_PAYLOAD_SIZE]; uint8_t cell_body[RELAY_PAYLOAD_SIZE];
trn_cell_establish_intro_t *cell = NULL; trn_cell_establish_intro_t *cell = NULL;
or_circuit_t *intro_circ = or_circuit_new(0,NULL);; or_circuit_t *intro_circ = or_circuit_new(0,NULL);
(void) arg; (void) arg;
@ -347,7 +347,7 @@ test_establish_intro_wrong_auth_key_len(void *arg)
ssize_t cell_len = 0; ssize_t cell_len = 0;
size_t bad_auth_key_len = ED25519_PUBKEY_LEN - 1; size_t bad_auth_key_len = ED25519_PUBKEY_LEN - 1;
trn_cell_establish_intro_t *cell = NULL; trn_cell_establish_intro_t *cell = NULL;
or_circuit_t *intro_circ = or_circuit_new(0,NULL);; or_circuit_t *intro_circ = or_circuit_new(0,NULL);
(void) arg; (void) arg;
@ -392,7 +392,7 @@ test_establish_intro_wrong_sig_len(void *arg)
ssize_t cell_len = 0; ssize_t cell_len = 0;
size_t bad_sig_len = ED25519_SIG_LEN - 1; size_t bad_sig_len = ED25519_SIG_LEN - 1;
trn_cell_establish_intro_t *cell = NULL; trn_cell_establish_intro_t *cell = NULL;
or_circuit_t *intro_circ = or_circuit_new(0,NULL);; or_circuit_t *intro_circ = or_circuit_new(0,NULL);
(void) arg; (void) arg;
@ -435,7 +435,7 @@ test_establish_intro_wrong_sig(void *arg)
char circ_nonce[DIGEST_LEN] = {0}; char circ_nonce[DIGEST_LEN] = {0};
uint8_t cell_body[RELAY_PAYLOAD_SIZE]; uint8_t cell_body[RELAY_PAYLOAD_SIZE];
ssize_t cell_len = 0; ssize_t cell_len = 0;
or_circuit_t *intro_circ = or_circuit_new(0,NULL);; or_circuit_t *intro_circ = or_circuit_new(0,NULL);
(void) arg; (void) arg;
@ -783,7 +783,7 @@ static void
test_received_introduce1_handling(void *arg) test_received_introduce1_handling(void *arg)
{ {
int ret; int ret;
uint8_t *request = NULL, buf[128];; uint8_t *request = NULL, buf[128];
trn_cell_introduce1_t *cell = NULL; trn_cell_introduce1_t *cell = NULL;
or_circuit_t *circ = NULL; or_circuit_t *circ = NULL;

View File

@ -282,7 +282,7 @@ test_have_enough_mem_for_dircache(void *arg)
or_options_t *opt=NULL; or_options_t *opt=NULL;
or_options_t *dflt=NULL; or_options_t *dflt=NULL;
config_line_t *cl=NULL; config_line_t *cl=NULL;
char *msg=NULL;; char *msg=NULL;
int r; int r;
const char *configuration = "ORPort 8080\nDirCache 1", *expect_errmsg; const char *configuration = "ORPort 8080\nDirCache 1", *expect_errmsg;

View File

@ -1290,7 +1290,7 @@ test_tortls_get_tlssecrets(void *ignored)
{ {
(void)ignored; (void)ignored;
int ret; int ret;
uint8_t *secret_out = tor_malloc_zero(DIGEST256_LEN);; uint8_t *secret_out = tor_malloc_zero(DIGEST256_LEN);
tor_tls_t *tls; tor_tls_t *tls;
tls = tor_malloc_zero(sizeof(tor_tls_t)); tls = tor_malloc_zero(sizeof(tor_tls_t));
tls->ssl = tor_malloc_zero(sizeof(SSL)); tls->ssl = tor_malloc_zero(sizeof(SSL));