tor/changes
Nick Mathewson bb465be085 Revise our assertion and bug macros to work with -Wparentheses
On GCC and Clang, there's a feature to warn you about bad
conditionals like "if (a = b)", which should be "if (a == b)".
However, they don't warn you if there are extra parentheses around
"a = b".

Unfortunately, the tor_assert() macro and all of its kin have been
passing their inputs through stuff like PREDICT_UNLIKELY(expr) or
PREDICT_UNLIKELY(!(expr)), both of which expand to stuff with more
parentheses around "expr", thus suppressing these warnings.

To fix this, this patch introduces new macros that do not wrap
expr.  They're only used when GCC or Clang is enabled (both define
__GNUC__), since they require GCC's "({statement expression})"
syntax extension.  They're only used when we're building the
unit-test variant of the object files, since they suppress the
branch-prediction hints.

I've confirmed that tor_assert(), tor_assert_nonfatal(),
tor_assert_nonfatal_once(), BUG(), and IF_BUG_ONCE() all now give
compiler warnings when their argument is an assignment expression.

Fixes bug 27709.

Bugfix on 0.0.6, where we first introduced the "tor_assert()" macro.
2018-09-14 11:39:37 -04:00
..
.dummy Add a .dummy file in the changes directory to stop git from removing it 2015-05-11 11:41:48 -04:00
19974 Increase tolerances in util/monotonic_time tests 2016-12-07 11:08:54 -05:00
20460 Make new changes files pass lintchanges 2016-11-07 16:19:05 -05:00
20492 Test for .git as readable instead of a dir to support worktrees 2016-12-05 08:21:17 -05:00
21359 Rework 21359 changes file slightly. 2017-02-01 10:39:48 -05:00
bastet_v6 Add bastet's ipv6 address 2017-11-27 09:09:16 -05:00
bug8185_025 Don't package cells onto marked circuits. 2017-09-29 09:33:47 -04:00
bug15582 Avoid sscanf() warnings from openbsd in the unit tests 2017-09-12 16:01:12 -04:00
bug18100 Fix the TRPOXY typo in connection_edge.c 2017-05-15 11:16:50 -04:00
bug18329-minimal Minimal implementation of bridge-distribution-request 2017-11-13 20:44:51 -05:00
bug19025 Changes file for 19025. 2017-01-18 09:01:26 -05:00
bug19869 Avoid tor_fragile_assert() failure with DNSPort on RESOLVED_TYPE_ERROR 2016-10-26 14:16:40 -04:00
bug19926_029_info Downgrade a harmless bug warning to info. 2016-12-09 08:43:09 -05:00
bug19960 Netbsd doesn't have ipfw, only the regular pf transport stuff. 2016-12-07 15:22:44 -05:00
bug19968 Actually clamp the number of detected CPUs to 16. 2016-10-31 14:19:39 -04:00
bug19969 Fix warnings from lintChanges.py 2016-11-06 16:39:46 -05:00
bug20059 Avoid a double-mark bug when makring a pending circuit as "too old" 2017-03-15 11:05:37 -04:00
bug20085 In torrc.sample.in, note that bandwidth must be >=75 KB. 2016-11-08 19:23:49 -05:00
bug20235 Try to work around breakage in the OSX 10.12 SDK. 2016-11-22 19:24:13 -05:00
bug20247 Allow setsockopt(IPV6_V6ONLY) in sandbox. 2017-07-05 13:09:21 -04:00
bug20306_029 policy_is_reject_star(): 2016-10-31 15:05:56 -04:00
bug20307 clean up grammar on bug20307 changes file 2017-01-22 19:03:12 -05:00
bug20401 Actually free the worker_state_t object when we do an update with it 2016-10-31 15:20:25 -04:00
bug20423 don't attempt a resolve when the cached answer will do 2016-11-16 16:22:11 -05:00
bug20424_029_minimal When setting a nonstandard malloc, disable the system malloc. 2018-07-11 09:37:29 -04:00
bug20472 Fix warnings from lintChanges.py 2016-11-06 16:39:46 -05:00
bug20484 Create single-onion-service directory before poisoning it, if needed 2016-10-31 14:54:20 -04:00
bug20487 Add a sentence to the manpage about nonanonymous=>Socksport 0. 2016-10-31 15:13:27 -04:00
bug20509 dir auths reject 0.2.9.x for x<5, due to bug 20499 2017-05-22 08:31:39 -04:00
bug20529 Check every hidden service directory's permissions when configuring 2016-11-02 14:32:04 +11:00
bug20533 When downloading certificates, check for related failures 2016-11-08 00:01:20 +11:00
bug20534 Adjust download schedules per teor's #20534 recommendataions 2016-11-07 11:01:20 -05:00
bug20536 Do not apply 'max_failures' to random-exponential schedules. 2016-11-06 20:08:11 -05:00
bug20551 Fix warnings from lintChanges.py 2016-11-06 16:39:46 -05:00
bug20553 Work around a behavior change in openssl's BUF_MEM code 2016-11-03 10:51:10 -04:00
bug20560 Use va_copy() in pure-windows version of tor_asprintf(). 2016-11-08 18:44:06 -05:00
bug20587 Make new changes files pass lintchanges 2016-11-07 16:19:05 -05:00
bug20588 Always Use EVP_aes_*_ctr() with openssl 1.1 2016-12-05 07:54:22 -05:00
bug20591 Ensure relays don't make multiple connections during bootstrap 2016-11-07 23:05:55 +11:00
bug20593 Count HTTP 503 as a download failure. 2016-11-07 11:01:21 -05:00
bug20597 When using exponential backoff in test networks, use a lower exponent 2016-11-08 16:42:26 +11:00
bug20613 Stop logging single onion and Tor2web long-term one-hop circuits 2016-11-09 11:23:51 +11:00
bug20634 Changes file for bug 20634 2016-11-16 13:14:03 +11:00
bug20638 Stop ignoring hidden service key anonymity when first starting tor 2016-12-01 09:44:53 -05:00
bug20710_025 Forgot to add changes file for 20710. 2016-12-07 10:51:39 -05:00
bug20715 router: Fix memory leak in signed_descriptor_move() 2016-12-09 08:30:46 -05:00
bug20716 Fix memory leak in bug 20716 2016-12-01 10:14:42 -05:00
bug20810 protover: Fix old tor hardcoded version check 2016-12-02 12:09:08 -05:00
bug20864 Fix changes file for 20864: 20638 _did_ get into 0.2.9 2016-12-05 08:12:10 -05:00
bug20875 Fix a BUG() warning from next_random_exponential_delay(). 2016-12-07 11:13:11 -05:00
bug20935 Spell MAC_OS_X_VERSION_10_12 correctly. 2016-12-11 22:17:14 -05:00
bug21018 Fix parsing bug with unecognized token at EOS 2016-12-18 20:17:24 -05:00
bug21035 changes file for 21035. 2016-12-23 08:08:14 -05:00
bug21051 Use event_base_new(), not event_init(), to detect libevent 2. 2016-12-23 08:18:31 -05:00
bug21074_downgrade fix make check-changes 2018-02-13 15:07:55 -06:00
bug21108_029 Do not clear is_bad_exit on sybil. 2017-01-31 14:12:14 -05:00
bug21278_extras changes file for removing compare-by-subtraction pattern 2017-02-14 16:32:59 -05:00
bug21278_prevention When examining descriptors as a dirserver, reject ones with bad versions 2017-02-15 07:46:34 -05:00
bug21280 changes file for 21280 2017-02-07 09:27:17 -05:00
bug21357 Changes file for 21357: Stop rejecting all IPv6 traffic on some Exits 2017-02-01 09:39:06 -05:00
bug21394 Fix DNS resolution on busy exit relays 2017-11-05 14:36:32 -05:00
bug21450 Limit version numbers to 0...INT32_MAX. 2017-02-15 07:57:34 -05:00
bug21507 Reject Tor versions that contain non-numeric prefixes 2017-02-19 22:38:06 +11:00
bug21576 Fix a crash when a connection tries to open just after it has been unlinked 2017-03-02 11:10:30 +11:00
bug21943 Add a changes file for 21943. 2017-05-08 13:39:59 -04:00
bug22034 control: Wrong check on base16_decode return value 2017-04-24 09:20:13 -04:00
bug22245 Fix a logic error in hibernate.c 2017-05-15 11:43:18 -04:00
bug22349 Mark descriptors as undownloadable when dirserv_add_() rejects them 2017-06-27 12:01:46 -04:00
bug22370 Stop leaking keypin-rejected routerinfos on directory authorities 2017-05-25 00:09:40 -04:00
bug22446 Fix GCC 7 -Wimplicit-fallthrough warnings (32 bit) 2017-09-11 17:45:07 -04:00
bug22460_case2 Changes file for the x509 link certificate case of bug22460 2017-06-05 15:27:33 -04:00
bug22490 Fix undefined behavior in geoip_parse_entry(). 2017-06-05 10:09:39 -04:00
bug22516 Permit the fchmod system call. 2017-06-16 14:03:02 -04:00
bug22636 Add a changes file for bug22636. 2017-07-17 21:44:59 +00:00
bug22644 Fix crashes on empty +HSPOST and +POSTDESCRIPTOR commands 2017-09-07 09:20:00 -04:00
bug22737 Fix an errant memset() into the middle of a struct in cell_pack(). 2017-06-27 10:47:20 -04:00
bug22789 Mention TROVE-2017-007 in changes file for 22789 2017-07-07 10:51:25 -04:00
bug22797 Always allow extra file descriptors when setting the connection maximum 2017-07-05 11:15:10 -04:00
bug22801 Fix -Wfloat-conversion C warnings on mingw in clamp_double_to_int64. 2017-07-03 10:59:31 -04:00
bug22838_028 mingw fix: avoid "unused var" warning. 2017-07-07 10:54:24 -04:00
bug22915 Suppress clang4-specific -Wdouble-promotion warnings 2017-07-26 12:53:00 -04:00
bug22916_027 Fix compiler warnings with openssl-scrypt/libscrypt test on clang 2017-07-13 17:49:48 -04:00
bug23030_029 Fix build warnings from Coverity related to our BUG macro 2017-07-26 12:57:49 -04:00
bug23081 In ntmain, call set_main_thread() before running the loop. 2017-08-03 09:09:08 -04:00
bug23291 changes file for bug 23291 2017-08-21 15:04:35 -04:00
bug23318 Use node counts in networks with all zero-bandwidths 2017-11-08 10:45:18 -05:00
bug23470 Stop relays calling directory_fetches_from_authorities on dir downloads 2017-09-13 09:46:17 +10:00
bug23690 Clear outbuf_flushlen when we clear a connection's outbuf 2017-09-29 10:00:14 -04:00
bug23693 Make changes in server_mode() affect workers; fix a crash. 2017-10-02 11:11:30 -04:00
bug23874 Clear the address when node_get_prim_orport() returns early 2017-10-15 16:48:36 -04:00
bug23985 Don't delay descriptor fetches when missing info needed for circuits 2017-11-08 13:22:16 -05:00
bug24167 Fix a traceback when closing a blocked connection "immediately". 2017-11-16 12:05:56 -05:00
bug24170 Actually log the total bandwidth in compute_weighted_bandwidths() 2017-11-08 10:45:18 -05:00
bug24198 Permit kill(pid, 0) in the seccomp2 sandbox. 2017-11-16 12:44:47 -05:00
bug24313 hs-v2: Remove any expiring intro from the retry list 2017-11-28 18:41:29 -05:00
bug24480 Fix a clang compilation warning in rendservice.c 2017-12-01 12:13:15 -05:00
bug24633 Fix the clz32 and clz64 settings on MSVC. 2017-12-20 09:37:18 -05:00
bug24666 Move destroy cells into a separate queue type of their own, to save RAM 2017-12-21 10:29:01 -05:00
bug24736 Clear the address when we can't choose a reachable address 2017-12-25 01:55:28 +11:00
bug24854 Lift the list of default directory servers into their own file. 2018-04-09 16:00:26 +02:00
bug24895 hs: Use hs_service_max_rdv_failures consensus param, defaulting to 2 2018-01-19 16:13:54 -05:00
bug24898-029 stop calling channel_mark_client in response to a create_fast 2018-02-16 08:46:31 -05:00
bug24952 channel_tls_get_remote_addr_method now returns real_addr. 2018-01-31 16:12:13 -05:00
bug24969 Permit the nanosleep system call in the seccomp2 callbox 2018-04-23 09:15:40 -04:00
bug24978 Make Tor support TLS1.3 ciphers with OpenSSL 1.1.1 2018-01-23 09:23:21 -05:00
bug25223 Make check-changes happy 2018-02-13 14:56:31 -05:00
bug25249 Forbid "-0" as a protocol version. 2018-03-01 16:05:17 -05:00
bug25249.2 Forbid UINT32_MAX as a protocol version 2018-03-01 16:05:17 -05:00
bug25440 Changes file for 25440 2018-08-08 09:26:21 -04:00
bug25629 Fix CID 1430932 2018-03-27 15:29:00 -05:00
bug26007 Stop logging stack contents when reading a zero-length bandwidth file 2018-05-02 22:36:23 +10:00
bug26072 Add a missing return after marking a stream for bad connected cell 2018-05-14 15:54:48 -04:00
bug26116 Return -1 from our PEM password callback 2018-05-16 11:39:42 -04:00
bug26196 Avoid out-of-bounds smartlist access in protover_compute_vote() 2018-06-08 10:11:32 -04:00
bug26269 Fix a GCC "potential null dereference" warning. 2018-06-13 10:34:53 -04:00
bug26485 Warn the directory authority operator if their versions list is bogus 2018-07-18 15:00:53 -04:00
bug26535.029 ntor_ref.py: pass only strings to subprocess.Popen 2018-07-02 14:18:41 -04:00
bug26787 Changes file for bug 26787 2018-07-18 16:39:22 -04:00
bug26830 SKIP test_keygen.sh on Windows until the underlying issue is resolved 2018-07-17 14:56:18 -04:00
bug26924 Stop logging link auth warnings on Single Onion Services and Tor2web 2018-07-25 14:30:33 +10:00
bug27081 Don't search for -lpthread on Windows 2018-08-08 09:56:51 -04:00
bug27088 Travis: create configure flags once, then echo the flags 2018-08-09 22:18:12 +10:00
bug27185 Silence a compilation warning on MSVC 2017 and clang-cl 2018-08-24 09:15:04 +10:00
bug27226 Rewrite test_tortls_cert_matches_key() 2018-08-20 17:43:41 -04:00
bug27295 Test: avoid spurious failures in make test-network-all 2018-08-29 10:47:20 +10:00
bug27344 Tell openssl to build its TLS contexts with security level 1 2018-09-07 09:15:06 -04:00
bug27418 Travis: don't call echo with a --flag as the first argument 2018-09-05 14:02:46 +10:00
bug27453 Travis: when showing a log fails, keep trying to show other logs 2018-09-05 13:12:54 +10:00
bug27461 Windows: Stop calling SetProcessDEPPolicy() on 64-bit Windows 2018-09-07 12:58:11 +10:00
bug27463 hs: Silence a spurious warning in rend_client_send_introduction() 2018-09-07 12:40:11 +10:00
bug27465 Windows: Silence a spurious warning in the GetAdaptersAddresses cast 2018-09-07 11:03:10 +10:00
bug27658 Check waitpid return value and exit status in tinytest.c 2018-09-12 08:57:18 -04:00
bug27709 Revise our assertion and bug macros to work with -Wparentheses 2018-09-14 11:39:37 -04:00
coveralls Add support for the coveralls.io coverage tool in travis config 2018-04-16 14:42:28 -04:00
feature25313 Add the poll() syscall as permitted by the sandbox 2018-03-20 08:23:44 -04:00
feature26372_029 Prefer recent Python 3 in autoconf. 2018-06-21 09:31:01 -04:00
geoip-2017-11-06 Update geoip and geoip6 to the November 6 2017 database. 2017-11-10 10:14:09 +01:00
geoip-2017-12-06 Update geoip and geoip6 to the December 6 2017 database. 2017-12-20 17:36:29 +01:00
geoip-2018-01-05 Update geoip and geoip6 to the January 5 2018 database. 2018-01-08 11:36:38 +01:00
geoip-2018-02-07 Update geoip and geoip6 to the February 7 2018 database. 2018-02-08 10:32:41 +01:00
geoip-2018-03-08 Update geoip and geoip6 to the March 8 2018 database. 2018-03-13 10:57:49 -04:00
geoip-2018-04-03 Update geoip and geoip6 to the April 3 2018 database. 2018-04-05 10:42:25 +02:00
geoip-2018-05-01 Update geoip and geoip6 to the May 1 2018 database. 2018-05-15 15:20:09 +02:00
geoip-2018-06-07 Update geoip and geoip6 to the June 7 2018 database. 2018-06-11 21:58:55 +02:00
geoip-2018-07-03 Update geoip and geoip6 to the July 3 2018 database. 2018-07-06 20:54:03 +02:00
geoip-2018-08-07 Update geoip and geoip6 to the August 7 2018 database. 2018-08-09 09:44:38 +02:00
geoip-2018-09-06 Update geoip and geoip6 to the September 6 2018 database. 2018-09-11 09:26:59 +02:00
geoip-april2017 Update geoip and geoip6 to the April 4 2017 database. 2017-04-06 10:52:39 +02:00
geoip-august2017 Update geoip and geoip6 to the August 3 2017 database. 2017-08-03 10:00:54 +02:00
geoip-december2016 Update geoip and geoip6 to the December 7 2016 database. 2016-12-09 10:23:36 +01:00
geoip-february2017 Update geoip and geoip6 to the February 8 2017 database. 2017-02-12 15:56:31 +01:00
geoip-january2017 fix a lintchanges warning 2017-01-22 18:48:22 -05:00
geoip-july2017 Update geoip and geoip6 to the July 4 2017 database. 2017-07-07 16:27:54 +02:00
geoip-june2017 Update geoip and geoip6 to the June 8 2017 database. 2017-06-09 15:47:49 +02:00
geoip-march2017 Update geoip and geoip6 to the March 7 2017 database. 2017-03-08 09:41:35 +01:00
geoip-may2017 Update geoip and geoip6 to the May 2 2017 database. 2017-05-08 10:09:42 +02:00
geoip-november2016 Make new changes files pass lintchanges 2016-11-07 16:19:05 -05:00
geoip-october2017 add missing subcategory in changes file 2017-10-05 11:04:54 -04:00
geoip-september2017 Update geoip and geoip6 to the September 6 2017 database. 2017-09-07 21:06:16 +02:00
longclaw_23592 Update Longclaw's IP address; fixes 23592. 2017-10-17 14:00:30 -04:00
longclaw-ipv6 Remove longclaw's IPv6 address, as it will soon change 2017-09-20 14:48:53 +10:00
more_module_docs changes file for module docs 2016-10-18 19:35:10 -04:00
prop275-minimal Stop declining to download microdescs with future published times. 2017-03-06 15:37:01 -05:00
task26771 put new bridge auth Serge into place 2018-07-12 14:12:13 -04:00
ticket19769 DefecTor countermeasure: change server- and client-side DNS TTL clipping 2017-01-18 08:55:57 -05:00
ticket20170-v3 Update the fallback directory mirror list in December 2016 2016-12-19 15:44:20 +11:00
ticket21564 Update fallback directory mirrors in May 2017 2017-05-16 19:02:42 +10:00
ticket21953 Enable some windows hardening features 2017-05-11 16:39:02 -04:00
ticket22895 Remove unused variables in donna's SSE2 code 2017-07-27 11:26:13 -04:00
ticket23856 relay: Change bandwidth stats interval to 24 hours 2017-11-27 10:00:40 -05:00
ticket23910 dirauth: Add bastet to the default authorities 2017-10-23 09:03:36 -04:00
ticket24315 Add a changes file. 2017-11-16 14:07:58 -05:00
ticket24629 Changes file for Travis: enable macOS builds 2018-08-10 12:10:56 +10:00
ticket24681 Make the default DirAuthorityFallbackRate 0.1 2017-12-23 00:01:31 +11:00
ticket24902 dos: Add changes file for ticket 24902 2018-01-30 09:18:16 -05:00
ticket25122 geoip: Hook the client history cache into the OOM handler 2018-02-02 14:48:41 -05:00
ticket25170 dirserv: Improve returned message when relay is rejected 2018-02-13 08:47:42 -05:00
ticket25202 Make check-changes happy 2018-02-13 14:56:31 -05:00
ticket26062 Having a ControlPort open doesn't mean we are a client 2018-05-09 12:50:53 -04:00
ticket26343 Add a changelog entry. 2018-06-12 09:44:01 -04:00
ticket26467 Changes file for 26467 2018-06-29 13:04:29 -04:00
ticket26560 Add more optional packages to Travis 2018-08-09 16:51:42 +10:00
ticket26952-ccache Travis: Use ccache 2018-08-09 22:18:53 +10:00
ticket27087 Travis: run an asciidoc build 2018-08-09 22:19:00 +10:00
ticket27252 Travis: Skip gcc on Linux with default settings 2018-08-23 18:13:53 +10:00
ticket_24801 Add changes file for new fallback directory list. 2018-01-08 11:09:08 -05:00
travis_distcheck Add distcheck support to travis configuration. 2018-04-18 17:33:19 -04:00
trove-2017-001 TROVE-2017-001 : move -ftrapv back into --expensive-hardening. 2017-01-23 08:47:10 -05:00
trove-2017-001.2 Avoid integer underflow in tor_version_compare. 2017-02-14 16:10:27 -05:00
trove-2017-005 TROVE-2017-005: Fix assertion failure in connection_edge_process_relay_cell 2017-06-08 09:21:10 -04:00
trove-2017-008 Fix log-uninitialized-stack bug in rend_service_intro_established. 2017-09-18 09:27:07 -04:00
trove-2017-009 Fix changes file 2017-11-30 11:52:40 -05:00
trove-2017-010 Handle NULL input to protover_compute_for_old_tor() 2017-11-27 15:16:30 -05:00
trove-2017-011 Avoid asking for passphrase on junky PEM input 2017-11-27 15:25:03 -05:00
trove-2017-012-part1 Use local descriptor object to exclude self in path selection 2017-11-28 19:14:10 -05:00
trove-2018-001.1 Correctly handle NULL returns from parse_protocol_list when voting. 2018-03-01 16:05:17 -05:00
trove-2018-004 Add another NULL-pointer fix for protover.c. 2018-03-01 16:05:17 -05:00