mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-03 17:13:33 +01:00
Merge branch 'maint-0.2.6' into release-0.2.6
This commit is contained in:
commit
7eb84e10e3
5
changes/bug15245
Normal file
5
changes/bug15245
Normal file
@ -0,0 +1,5 @@
|
||||
o Major bugfixes:
|
||||
- Avoid crashing when making certain configuration option changes
|
||||
on clients. Fixes bug 15245; bugfix on 0.2.6.3-alpha. Reported
|
||||
by "anonym".
|
||||
|
4
changes/bug9495_redux
Normal file
4
changes/bug9495_redux
Normal file
@ -0,0 +1,4 @@
|
||||
o Major bugfixes (portability):
|
||||
- Do not crash on startup when running on Solaris. Fixes a bug
|
||||
related to our fix for 9495; bugfix on 0.2.6.1-alpha. Reported
|
||||
by "ruebezahl".
|
@ -279,7 +279,11 @@ tor_threads_init(void)
|
||||
pthread_mutexattr_init(&attr_recursive);
|
||||
pthread_mutexattr_settype(&attr_recursive, PTHREAD_MUTEX_RECURSIVE);
|
||||
tor_assert(0==pthread_attr_init(&attr_detached));
|
||||
tor_assert(0==pthread_attr_setdetachstate(&attr_detached, 1));
|
||||
#ifndef PTHREAD_CREATE_DETACHED
|
||||
#define PTHREAD_CREATE_DETACHED 1
|
||||
#endif
|
||||
tor_assert(0==pthread_attr_setdetachstate(&attr_detached,
|
||||
PTHREAD_CREATE_DETACHED));
|
||||
threads_initialized = 1;
|
||||
set_main_thread();
|
||||
}
|
||||
|
@ -256,7 +256,6 @@ char *smartlist_join_strings2(smartlist_t *sl, const char *join,
|
||||
--var ## _sl_len; \
|
||||
STMT_END
|
||||
|
||||
|
||||
/** Helper: While in a SMARTLIST_FOREACH loop over the list <b>sl</b> indexed
|
||||
* with the variable <b>var</b>, replace the current element with <b>val</b>.
|
||||
* Does not deallocate the current value of <b>var</b>.
|
||||
|
@ -178,6 +178,12 @@ update_state_threadfn(void *state_, void *work_)
|
||||
void
|
||||
cpuworkers_rotate_keyinfo(void)
|
||||
{
|
||||
if (!threadpool) {
|
||||
/* If we're a client, then we won't have cpuworkers, and we won't need
|
||||
* to tell them to rotate their state.
|
||||
*/
|
||||
return;
|
||||
}
|
||||
if (threadpool_queue_update(threadpool,
|
||||
worker_state_new,
|
||||
update_state_threadfn,
|
||||
@ -486,6 +492,8 @@ assign_onionskin_to_cpuworker(or_circuit_t *circ,
|
||||
cpuworker_request_t req;
|
||||
int should_time;
|
||||
|
||||
tor_assert(threadpool);
|
||||
|
||||
if (!circ->p_chan) {
|
||||
log_info(LD_OR,"circ->p_chan gone. Failing circ.");
|
||||
tor_free(onionskin);
|
||||
|
@ -878,7 +878,8 @@ NS(logv)(int severity, log_domain_mask_t domain, const char *funcname,
|
||||
tt_ptr_op(strstr(funcname, "log_heartbeat"), OP_NE, NULL);
|
||||
tt_ptr_op(suffix, OP_EQ, NULL);
|
||||
tt_str_op(format, OP_EQ,
|
||||
"Average packaged cell fullness: %2.3f%%. TLS write overhead: %.f%%");
|
||||
"Average packaged cell fullness: %2.3f%%. "
|
||||
"TLS write overhead: %.f%%");
|
||||
tt_double_op(fabs(va_arg(ap, double) - 50.0), <=, DBL_EPSILON);
|
||||
tt_double_op(fabs(va_arg(ap, double) - 0.0), <=, DBL_EPSILON);
|
||||
break;
|
||||
@ -1026,7 +1027,8 @@ NS(logv)(int severity, log_domain_mask_t domain,
|
||||
tt_ptr_op(strstr(funcname, "log_heartbeat"), OP_NE, NULL);
|
||||
tt_ptr_op(suffix, OP_EQ, NULL);
|
||||
tt_str_op(format, OP_EQ,
|
||||
"Average packaged cell fullness: %2.3f%%. TLS write overhead: %.f%%");
|
||||
"Average packaged cell fullness: %2.3f%%. "
|
||||
"TLS write overhead: %.f%%");
|
||||
tt_int_op(fabs(va_arg(ap, double) - 100.0) <= DBL_EPSILON, OP_EQ, 1);
|
||||
tt_double_op(fabs(va_arg(ap, double) - 100.0), <=, DBL_EPSILON);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user