mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2025-02-25 15:10:48 +01:00
Merge branch 'maint-0.4.3' into maint-0.4.4
This commit is contained in:
commit
4c82c2d1d4
6 changed files with 19 additions and 12 deletions
4
changes/40241_v2
Normal file
4
changes/40241_v2
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
o Minor bugfixes (compilation):
|
||||||
|
- Fix another warning about unreachable fallthrough annotations
|
||||||
|
when building with "--enable-all-bugs-are-fatal" on some compilers.
|
||||||
|
Fixes bug 40241; bugfix on 0.4.5.3-rc.
|
|
@ -1226,9 +1226,7 @@ channel_tls_handle_var_cell(var_cell_t *var_cell, or_connection_t *conn)
|
||||||
* the v2 and v3 handshakes. */
|
* the v2 and v3 handshakes. */
|
||||||
/* But that should be happening any longer've disabled bufferevents. */
|
/* But that should be happening any longer've disabled bufferevents. */
|
||||||
tor_assert_nonfatal_unreached_once();
|
tor_assert_nonfatal_unreached_once();
|
||||||
#ifndef ALL_BUGS_ARE_FATAL
|
FALLTHROUGH_UNLESS_ALL_BUGS_ARE_FATAL;
|
||||||
FALLTHROUGH;
|
|
||||||
#endif
|
|
||||||
case OR_CONN_STATE_TLS_SERVER_RENEGOTIATING:
|
case OR_CONN_STATE_TLS_SERVER_RENEGOTIATING:
|
||||||
if (!(command_allowed_before_handshake(var_cell->command))) {
|
if (!(command_allowed_before_handshake(var_cell->command))) {
|
||||||
log_fn(LOG_PROTOCOL_WARN, LD_PROTOCOL,
|
log_fn(LOG_PROTOCOL_WARN, LD_PROTOCOL,
|
||||||
|
|
|
@ -846,9 +846,7 @@ circuit_purpose_to_controller_hs_state_string(uint8_t purpose)
|
||||||
"Unrecognized circuit purpose: %d",
|
"Unrecognized circuit purpose: %d",
|
||||||
(int)purpose);
|
(int)purpose);
|
||||||
tor_fragile_assert();
|
tor_fragile_assert();
|
||||||
#ifndef ALL_BUGS_ARE_FATAL
|
FALLTHROUGH_UNLESS_ALL_BUGS_ARE_FATAL;
|
||||||
FALLTHROUGH;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
case CIRCUIT_PURPOSE_OR:
|
case CIRCUIT_PURPOSE_OR:
|
||||||
case CIRCUIT_PURPOSE_C_GENERAL:
|
case CIRCUIT_PURPOSE_C_GENERAL:
|
||||||
|
|
|
@ -2317,9 +2317,7 @@ entry_guards_note_guard_success(guard_selection_t *gs,
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
tor_assert_nonfatal_unreached();
|
tor_assert_nonfatal_unreached();
|
||||||
#ifndef ALL_BUGS_ARE_FATAL
|
FALLTHROUGH_UNLESS_ALL_BUGS_ARE_FATAL;
|
||||||
FALLTHROUGH;
|
|
||||||
#endif
|
|
||||||
case GUARD_CIRC_STATE_USABLE_IF_NO_BETTER_GUARD:
|
case GUARD_CIRC_STATE_USABLE_IF_NO_BETTER_GUARD:
|
||||||
if (guard->is_primary) {
|
if (guard->is_primary) {
|
||||||
/* XXXX #20832 -- I don't actually like this logic. It seems to make
|
/* XXXX #20832 -- I don't actually like this logic. It seems to make
|
||||||
|
|
|
@ -831,9 +831,7 @@ rend_client_report_intro_point_failure(extend_info_t *failed_intro,
|
||||||
log_warn(LD_BUG, "Unknown failure type %u. Removing intro point.",
|
log_warn(LD_BUG, "Unknown failure type %u. Removing intro point.",
|
||||||
failure_type);
|
failure_type);
|
||||||
tor_fragile_assert();
|
tor_fragile_assert();
|
||||||
#ifndef ALL_BUGS_ARE_FATAL
|
FALLTHROUGH_UNLESS_ALL_BUGS_ARE_FATAL;
|
||||||
FALLTHROUGH;
|
|
||||||
#endif
|
|
||||||
case INTRO_POINT_FAILURE_GENERIC:
|
case INTRO_POINT_FAILURE_GENERIC:
|
||||||
rend_cache_intro_failure_note(failure_type,
|
rend_cache_intro_failure_note(failure_type,
|
||||||
(uint8_t *)failed_intro->identity_digest,
|
(uint8_t *)failed_intro->identity_digest,
|
||||||
|
|
|
@ -249,6 +249,17 @@
|
||||||
|
|
||||||
#endif /* defined(ALL_BUGS_ARE_FATAL) || ... */
|
#endif /* defined(ALL_BUGS_ARE_FATAL) || ... */
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Use this macro after a nonfatal assertion, and before a case statement
|
||||||
|
* where you would want to fall through.
|
||||||
|
*/
|
||||||
|
#ifdef ALL_BUGS_ARE_FATAL
|
||||||
|
#define FALLTHROUGH_UNLESS_ALL_BUGS_ARE_FATAL \
|
||||||
|
abort()
|
||||||
|
#else
|
||||||
|
#define FALLTHROUGH_UNLESS_ALL_BUGS_ARE_FATAL FALLTHROUGH
|
||||||
|
#endif
|
||||||
|
|
||||||
/** In older code, we used tor_fragile_assert() to mark optional failure
|
/** In older code, we used tor_fragile_assert() to mark optional failure
|
||||||
* points. At these points, we could make some debug builds fail.
|
* points. At these points, we could make some debug builds fail.
|
||||||
* (But release builds would continue.)
|
* (But release builds would continue.)
|
||||||
|
|
Loading…
Add table
Reference in a new issue