more fixes for typos, grammar, whitespace, etc

some of these ought to have been noticed by the "misspell" tool,
so if anybody is debugging it, here are some bug reports :)
This commit is contained in:
Roger Dingledine 2018-02-07 12:22:29 -05:00
parent 78382d557a
commit a7440d9c9d
18 changed files with 30 additions and 33 deletions

View File

@ -444,7 +444,7 @@ Changes in version 0.3.2.9 - 2018-01-09
o Minor bugfixes (portability, msvc):
- Fix a bug in the bit-counting parts of our timing-wheel code on
MSVC. (Note that MSVC is still not a supported build platform, due
to cyptographic timing channel risks.) Fixes bug 24633; bugfix
to cryptographic timing channel risks.) Fixes bug 24633; bugfix
on 0.2.9.1-alpha.

View File

@ -621,7 +621,7 @@ Changes in version 0.3.2.9 - 2018-01-09
Hurd. Fixes bug 23098; bugfix on 0.3.1.1-alpha.
- Fix a bug in the bit-counting parts of our timing-wheel code on
MSVC. (Note that MSVC is still not a supported build platform, due
to cyptographic timing channel risks.) Fixes bug 24633; bugfix
to cryptographic timing channel risks.) Fixes bug 24633; bugfix
on 0.2.9.1-alpha.
o Minor bugfixes (relay):

View File

@ -2890,7 +2890,7 @@ compute_num_cpus(void)
/** Helper: Deal with confused or out-of-bounds values from localtime_r and
* friends. (On some platforms, they can give out-of-bounds values or can
* return NULL.) If <b>islocal</b>, this is a localtime result; otherwise
* it's from gmtime. The function returned <b>r</b>, when given <b>timep</b>
* it's from gmtime. The function returns <b>r</b>, when given <b>timep</b>
* as its input. If we need to store new results, store them in
* <b>resultbuf</b>. */
static struct tm *

View File

@ -1915,7 +1915,7 @@ crypto_strongest_rand_syscall(uint8_t *out, size_t out_len)
return 0;
#elif defined(__linux__) && defined(SYS_getrandom)
static int getrandom_works = 1; /* Be optimitic about our chances... */
static int getrandom_works = 1; /* Be optimistic about our chances... */
/* getrandom() isn't as straightforward as getentropy(), and has
* no glibc wrapper.

View File

@ -1435,7 +1435,6 @@ channel_clear_remote_end(channel_t *chan)
/**
* Write to a channel the given packed cell.
*
*
* Two possible errors can happen. Either the channel is not opened or the
* lower layer (specialized channel) failed to write it. In both cases, it is
* the caller responsibility to free the cell.
@ -1864,12 +1863,11 @@ channel_listener_process_incoming(channel_listener_t *listener)
* this comes from the old connection_or_set_state_open() of connection_or.c.
*
* Because of this mechanism, future channel_t subclasses should take care
* not to change a channel to from CHANNEL_STATE_OPENING to CHANNEL_STATE_OPEN
* not to change a channel from CHANNEL_STATE_OPENING to CHANNEL_STATE_OPEN
* until there is positive confirmation that the network is operational.
* In particular, anything UDP-based should not make this transition until a
* packet is received from the other side.
*/
void
channel_do_open_actions(channel_t *chan)
{
@ -3199,7 +3197,7 @@ channel_num_cells_writeable(channel_t *chan)
********************/
/**
* Update the created timestamp for a channel
* Update the created timestamp for a channel.
*
* This updates the channel's created timestamp and should only be called
* from channel_init().
@ -3216,7 +3214,7 @@ channel_timestamp_created(channel_t *chan)
}
/**
* Update the created timestamp for a channel listener
* Update the created timestamp for a channel listener.
*
* This updates the channel listener's created timestamp and should only be
* called from channel_init_listener().
@ -3233,7 +3231,7 @@ channel_listener_timestamp_created(channel_listener_t *chan_l)
}
/**
* Update the last active timestamp for a channel
* Update the last active timestamp for a channel.
*
* This function updates the channel's last active timestamp; it should be
* called by the lower layer whenever there is activity on the channel which
@ -3258,9 +3256,8 @@ channel_timestamp_active(channel_t *chan)
}
/**
* Update the last active timestamp for a channel listener
* Update the last active timestamp for a channel listener.
*/
void
channel_listener_timestamp_active(channel_listener_t *chan_l)
{
@ -3278,7 +3275,6 @@ channel_listener_timestamp_active(channel_listener_t *chan_l)
* should be called whenever a new incoming channel is accepted on a
* listener.
*/
void
channel_listener_timestamp_accepted(channel_listener_t *chan_l)
{
@ -3308,7 +3304,7 @@ channel_timestamp_client(channel_t *chan)
}
/**
* Update the recv timestamp
* Update the recv timestamp.
*
* This is called whenever we get an incoming cell from the lower layer.
* This also updates the active timestamp.
@ -3329,7 +3325,8 @@ channel_timestamp_recv(channel_t *chan)
}
/**
* Update the xmit timestamp
* Update the xmit timestamp.
*
* This is called whenever we pass an outgoing cell to the lower layer. This
* also updates the active timestamp.
*/

View File

@ -69,7 +69,7 @@ static int consensus_nf_pad_single_onion;
/**
* This macro tells us if either end of the channel is connected to a client.
* (If we're not a server, we're definitely a client. If the channel thinks
* its a client, use that. Then finally verify in the consensus).
* it's a client, use that. Then finally verify in the consensus).
*/
#define CHANNEL_IS_CLIENT(chan, options) \
(!public_server_mode((options)) || channel_is_client(chan) || \

View File

@ -1588,7 +1588,7 @@ channel_tls_process_versions_cell(var_cell_t *cell, channel_tls_t *chan)
}
}
/* We set this after sending the verions cell. */
/* We set this after sending the versions cell. */
/*XXXXX symbolic const.*/
TLS_CHAN_TO_BASE(chan)->wide_circ_ids =
chan->conn->link_proto >= MIN_LINK_PROTO_FOR_WIDE_CIRC_IDS;

View File

@ -286,7 +286,7 @@ command_process_create_cell(cell_t *cell, channel_t *chan)
"Received create cell but we're shutting down. Sending back "
"destroy.");
channel_send_destroy(cell->circ_id, chan,
END_CIRC_REASON_HIBERNATING);
END_CIRC_REASON_HIBERNATING);
return;
}

View File

@ -250,7 +250,7 @@ should_time_request(uint16_t onionskin_type)
}
/** Return an estimate of how many microseconds we will need for a single
* cpuworker to to process <b>n_requests</b> onionskins of type
* cpuworker to process <b>n_requests</b> onionskins of type
* <b>onionskin_type</b>. */
uint64_t
estimated_usec_for_onionskins(uint32_t n_requests, uint16_t onionskin_type)

View File

@ -702,7 +702,7 @@ cache_clean_v3_as_client(time_t now)
/* Entry is not in the cache anymore, destroy it. */
cache_client_desc_free(entry);
/* Update our OOM. We didn't use the remove() function because we are in
* a loop so we have to explicitey decrement. */
* a loop so we have to explicitly decrement. */
rend_cache_decrement_allocation(entry_size);
/* Logging. */
{

View File

@ -699,12 +699,12 @@ hs_circ_service_get_intro_circ(const hs_service_intro_point_t *ip)
*
* We currently relaunch connections to rendezvous points if:
* - A rendezvous circuit timed out before connecting to RP.
* - The redenzvous circuit failed to connect to the RP.
* - The rendezvous circuit failed to connect to the RP.
*
* We avoid relaunching a connection to this rendezvous point if:
* - We have already tried MAX_REND_FAILURES times to connect to this RP.
* - We have already tried MAX_REND_FAILURES times to connect to this RP,
* - We've been trying to connect to this RP for more than MAX_REND_TIMEOUT
* seconds
* seconds, or
* - We've already retried this specific rendezvous circuit.
*/
void
@ -718,11 +718,11 @@ hs_circ_retry_service_rendezvous_point(origin_circuit_t *circ)
goto done;
}
/* Flag the circuit that we are relaunching so to avoid to relaunch twice a
/* Flag the circuit that we are relaunching, to avoid to relaunch twice a
* circuit to the same rendezvous point at the same time. */
circ->hs_service_side_rend_circ_has_been_relaunched = 1;
/* Legacy service don't have an hidden service ident. */
/* Legacy service don't have a hidden service ident. */
if (circ->hs_ident) {
retry_service_rendezvous_point(circ);
} else {

View File

@ -3376,7 +3376,7 @@ tor_init(int argc, char *argv[])
log_warn(LD_NET, "Problem initializing libevent RNG.");
}
/* Scan/clean unparseable descroptors; after reading config */
/* Scan/clean unparseable descriptors; after reading config */
routerparse_init();
return 0;

View File

@ -5380,7 +5380,7 @@ typedef struct rend_intro_point_t {
*/
int accepted_introduce2_count;
/** (Service side only) Number of maximum INTRODUCE2 cells that this IP
/** (Service side only) Maximum number of INTRODUCE2 cells that this IP
* will accept. This is a random value between
* INTRO_POINT_MIN_LIFETIME_INTRODUCTIONS and
* INTRO_POINT_MAX_LIFETIME_INTRODUCTIONS. */

View File

@ -48,7 +48,7 @@ STATIC digestmap_t *rend_cache_v2_dir = NULL;
* Once a descriptor is removed from the rend cache or expires, the entry
* in this cache is also removed for the service ID.
*
* This scheme allows us to not relay on the descriptor's timestamp (which
* This scheme allows us to not rely on the descriptor's timestamp (which
* is rounded down to the hour) to know if we have a newer descriptor. We
* only rely on the usability of intro points from an internal state. */
STATIC strmap_t *rend_cache_failure = NULL;

View File

@ -4286,7 +4286,7 @@ rend_service_dump_stats(int severity)
}
/** Given <b>conn</b>, a rendezvous exit stream, look up the hidden service for
* 'circ', and look up the port and address based on conn-\>port.
* <b>circ</b>, and look up the port and address based on conn-\>port.
* Assign the actual conn-\>addr and conn-\>port. Return -2 on failure
* for which the circuit should be closed, -1 on other failure,
* or 0 for success.

View File

@ -235,7 +235,7 @@ get_n_authorities(dirinfo_type_t type)
return n;
}
/** Initialise schedule, want_authority, and increment on in the download
/** Initialise schedule, want_authority, and increment_on in the download
* status dlstatus, then call download_status_reset() on it.
* It is safe to call this function or download_status_reset() multiple times
* on a new dlstatus. But it should *not* be called after a dlstatus has been
@ -1170,7 +1170,7 @@ authority_certs_fetch_missing(networkstatus_t *status, time_t now,
} SMARTLIST_FOREACH_END(voter);
}
/* Bridge clients look up the node for the dir_hint */
/* Bridge clients look up the node for the dir_hint */
const node_t *node = NULL;
/* All clients, including bridge clients, look up the routerstatus for the
* dir_hint */

View File

@ -373,7 +373,7 @@ set_scheduler_run_interval(void)
}
}
/* Return true iff the channel hasnt hit its kist-imposed write limit yet */
/* Return true iff the channel hasn't hit its kist-imposed write limit yet */
static int
socket_can_write(socket_table_t *table, const channel_t *chan)
{

View File

@ -42,7 +42,7 @@ count_circuits(void)
}
/** Take seconds <b>secs</b> and return a newly allocated human-readable
* uptime string */
* uptime string. */
STATIC char *
secs_to_uptime(long secs)
{