]> git.ipfire.org Git - thirdparty/tor.git/log
thirdparty/tor.git
6 years agoMerge remote-tracking branch 'tor-github/pr/1373' into maint-0.4.2
teor [Thu, 17 Oct 2019 04:51:30 +0000 (14:51 +1000)] 
Merge remote-tracking branch 'tor-github/pr/1373' into maint-0.4.2

6 years agomaint-0.4.2: remove ".enable_practracker_in_hooks".
Nick Mathewson [Fri, 11 Oct 2019 21:18:55 +0000 (17:18 -0400)] 
maint-0.4.2: remove ".enable_practracker_in_hooks".

6 years agoMerge branch 'ticket31682_042_01_squashed'
Nick Mathewson [Fri, 11 Oct 2019 14:21:58 +0000 (10:21 -0400)] 
Merge branch 'ticket31682_042_01_squashed'

6 years agoCorrect comment on build_establish_intro_dos_extension
Nick Mathewson [Fri, 11 Oct 2019 14:21:45 +0000 (10:21 -0400)] 
Correct comment on build_establish_intro_dos_extension

6 years agohs-v3: Fix implicit ssize_t to size_t conversion
David Goulet [Wed, 2 Oct 2019 17:19:51 +0000 (13:19 -0400)] 
hs-v3: Fix implicit ssize_t to size_t conversion

Found by Coverity.

Fixes #31682

Signed-off-by: David Goulet <dgoulet@torproject.org>
6 years agoMerge remote-tracking branch 'tor-github/pr/1394'
Nick Mathewson [Wed, 9 Oct 2019 20:44:12 +0000 (16:44 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1394'

6 years agoMerge remote-tracking branch 'tor-github/pr/1399'
Nick Mathewson [Wed, 9 Oct 2019 20:37:47 +0000 (16:37 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1399'

6 years agoMerge remote-tracking branch 'tor-github/pr/1401'
Nick Mathewson [Wed, 9 Oct 2019 20:29:46 +0000 (16:29 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1401'

6 years agoMerge branch 'bug30344_squashed_035'
Nick Mathewson [Wed, 9 Oct 2019 20:26:31 +0000 (16:26 -0400)] 
Merge branch 'bug30344_squashed_035'

6 years agoStop libevent from reading data from closed connections.
George Kadianakis [Mon, 30 Sep 2019 15:29:00 +0000 (18:29 +0300)] 
Stop libevent from reading data from closed connections.

Code adapted from Rob's proposed patch in #30344.

Also add a comment in connection_mark_for_close_internal_() on why we should
not be adding extra code there without a very good reason.

6 years agotest: New behavior on IP retry for HSv3
Neel Chauhan [Wed, 18 Sep 2019 15:40:10 +0000 (11:40 -0400)] 
test: New behavior on IP retry for HSv3

Unit test for #31652 where if we are over the retry limit for the IP but we
have an established circuit, we don't remove the IP.

Part of #31652

6 years agohs-v3: Do not remove intro point if circuit exists
David Goulet [Tue, 10 Sep 2019 18:40:40 +0000 (14:40 -0400)] 
hs-v3: Do not remove intro point if circuit exists

When considering introduction point of a service's descriptor, do not remove
an intro point that has an established or pending circuit.

Fixes #31652

Signed-off-by: David Goulet <dgoulet@torproject.org>
6 years agoMerge branch 'tor-github/pr/1381'
David Goulet [Tue, 8 Oct 2019 18:49:39 +0000 (14:49 -0400)] 
Merge branch 'tor-github/pr/1381'

6 years agoFix flapping of test_service_intro_point() unittest.
George Kadianakis [Tue, 8 Oct 2019 15:59:27 +0000 (18:59 +0300)] 
Fix flapping of test_service_intro_point() unittest.

6 years agoMerge remote-tracking branch 'tor-github/pr/1317'
Nick Mathewson [Mon, 7 Oct 2019 14:23:44 +0000 (10:23 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1317'

6 years agoMerge branch 'ticket31548_035_01_squashed'
Nick Mathewson [Mon, 7 Oct 2019 14:21:40 +0000 (10:21 -0400)] 
Merge branch 'ticket31548_035_01_squashed'

6 years agohs-v3: Make service pick the exact amount of intro points
David Goulet [Thu, 29 Aug 2019 14:46:24 +0000 (10:46 -0400)] 
hs-v3: Make service pick the exact amount of intro points

When encoding introduction points, we were not checking if that intro points
had an established circuit.

When botting up, the service will pick, by default, 3 + 2 intro points and the
first 3 that establish, we use them and upload the descriptor.

However, the intro point is removed from the service descriptor list only when
the circuit has opened and we see that we have already enough intro points, it
is then removed.

But it is possible that the service establishes 3 intro points successfully
before the other(s) have even opened yet.

This lead to the service encoding extra intro points in the descriptor even
though the circuit is not opened or might never establish (#31561).

Fixes #31548

Signed-off-by: David Goulet <dgoulet@torproject.org>
6 years agoMerge remote-tracking branch 'tor-github/pr/1379'
Nick Mathewson [Mon, 7 Oct 2019 14:15:46 +0000 (10:15 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1379'

6 years agoMerge remote-tracking branch 'tor-github/pr/1390'
Nick Mathewson [Mon, 7 Oct 2019 14:13:32 +0000 (10:13 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1390'

6 years agobump to 0.4.2.2-alpha-dev
Nick Mathewson [Mon, 7 Oct 2019 13:32:26 +0000 (09:32 -0400)] 
bump to 0.4.2.2-alpha-dev

6 years agofix typo in how-to-review guidelines tor-0.4.2.2-alpha
Roger Dingledine [Mon, 7 Oct 2019 04:48:11 +0000 (00:48 -0400)] 
fix typo in how-to-review guidelines

6 years agotls: Log TLS read buffer length bugs once
teor [Fri, 4 Oct 2019 02:33:34 +0000 (12:33 +1000)] 
tls: Log TLS read buffer length bugs once

Rather than filling the logs with similar warnings.

Fixes bug 31939; bugfix on 0.3.0.4-rc.

6 years agoMerge remote-tracking branch 'tor-github/pr/1392'
teor [Fri, 4 Oct 2019 01:26:43 +0000 (11:26 +1000)] 
Merge remote-tracking branch 'tor-github/pr/1392'

6 years agohs: ADD_ONION NEW:BEST now defaults to ED25519-V3
David Goulet [Wed, 11 Sep 2019 12:46:31 +0000 (08:46 -0400)] 
hs: ADD_ONION NEW:BEST now defaults to ED25519-V3

From RSA1024 (v2) to v3 now.

Closes #29669

Signed-off-by: David Goulet <dgoulet@torproject.org>
6 years agoPick a release date for 0.4.2.2-alpha
Nick Mathewson [Thu, 3 Oct 2019 18:58:51 +0000 (14:58 -0400)] 
Pick a release date for 0.4.2.2-alpha

6 years agoLight edits on 0.4.2.2-alpha changelog.
Nick Mathewson [Thu, 3 Oct 2019 16:34:21 +0000 (12:34 -0400)] 
Light edits on 0.4.2.2-alpha changelog.

6 years agolightly sort changelog entries
Nick Mathewson [Thu, 3 Oct 2019 16:24:47 +0000 (12:24 -0400)] 
lightly sort changelog entries

6 years agoRun format_changelog
Nick Mathewson [Thu, 3 Oct 2019 16:23:05 +0000 (12:23 -0400)] 
Run format_changelog

6 years agoSort changes entries into a changelog for 0.4.2.2-alpha
Nick Mathewson [Thu, 3 Oct 2019 16:22:46 +0000 (12:22 -0400)] 
Sort changes entries into a changelog for 0.4.2.2-alpha

6 years agoMerge branch 'tor-github/pr/1377'
George Kadianakis [Thu, 3 Oct 2019 16:13:57 +0000 (19:13 +0300)] 
Merge branch 'tor-github/pr/1377'

6 years agoMerge branch 'tor-github/pr/1276'
George Kadianakis [Thu, 3 Oct 2019 16:13:02 +0000 (19:13 +0300)] 
Merge branch 'tor-github/pr/1276'

6 years agoUnit tests for dirserv_reject_tor_version().
Nick Mathewson [Thu, 29 Aug 2019 15:45:41 +0000 (11:45 -0400)] 
Unit tests for dirserv_reject_tor_version().

6 years agoAuthorities reject relays running unsupported Tor release series.
Nick Mathewson [Thu, 29 Aug 2019 15:43:43 +0000 (11:43 -0400)] 
Authorities reject relays running unsupported Tor release series.

Our minimum version is now 0.2.9.5-alpha.  Series 0.3.0, 0.3.1,
0.3.2, 0.3.3, and 0.3.4 are now rejected.

Also, extract this version-checking code into a new function, so we
can test it.

Closes ticket 31549.

Also reject 0.3.5.0 through 0.3.5.6-rc as unstable.

6 years agobump to 0.4.2.2-alpha
Nick Mathewson [Thu, 3 Oct 2019 16:07:50 +0000 (12:07 -0400)] 
bump to 0.4.2.2-alpha

6 years agoMerge remote-tracking branch 'tor-github/pr/1376'
Nick Mathewson [Thu, 3 Oct 2019 13:19:37 +0000 (09:19 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1376'

6 years agoMerge remote-tracking branch 'tor-github/pr/1358'
Nick Mathewson [Thu, 3 Oct 2019 13:11:49 +0000 (09:11 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1358'

6 years agoMerge remote-tracking branch 'tor-github/pr/1382'
Nick Mathewson [Thu, 3 Oct 2019 13:08:23 +0000 (09:08 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1382'

6 years agoutil/map_anon_nofork: Add a cast to avoid passing -48 to memset
Nick Mathewson [Thu, 3 Oct 2019 11:21:25 +0000 (07:21 -0400)] 
util/map_anon_nofork: Add a cast to avoid passing -48 to memset

This fixes coverity CID 1454593, and bug 31948. Bug not in any
released version of Tor.

6 years agoconfigure: List the env vars needed if pkg-config doesn't work
teor [Thu, 3 Oct 2019 06:53:12 +0000 (16:53 +1000)] 
configure: List the env vars needed if pkg-config doesn't work

Part of 31922.

6 years agoconfigure: Fix a typo in the systemd version message
teor [Thu, 3 Oct 2019 06:32:30 +0000 (16:32 +1000)] 
configure: Fix a typo in the systemd version message

6 years agoconfigure: Give a more useful message when pkg-config fails
teor [Thu, 3 Oct 2019 06:31:20 +0000 (16:31 +1000)] 
configure: Give a more useful message when pkg-config fails

When pkg-config is not installed, or a library that depends on
pkg-config is not found, tell the user what to do to fix the
problem.

Fixes bug 31922; bugfix on 0.3.1.1-alpha.

6 years agocontrol/control: Refactor some error handling code
teor [Mon, 5 Aug 2019 14:18:41 +0000 (00:18 +1000)] 
control/control: Refactor some error handling code

Split some protocol error handling out of
connection_control_process_inbuf().

This refactor reduces the size of a practracker exception.

Closes 31840.

6 years agoMerge remote-tracking branch 'tor-github/pr/1374'
Nick Mathewson [Wed, 2 Oct 2019 23:19:11 +0000 (19:19 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1374'

6 years agoMerge branch 'tor-github/pr/1385'
David Goulet [Wed, 2 Oct 2019 18:15:31 +0000 (14:15 -0400)] 
Merge branch 'tor-github/pr/1385'

6 years agoMerge branch 'tor-github/pr/1344'
David Goulet [Wed, 2 Oct 2019 14:37:49 +0000 (10:37 -0400)] 
Merge branch 'tor-github/pr/1344'

6 years agoMerge branch 'tor-github/pr/1363'
David Goulet [Wed, 2 Oct 2019 14:34:46 +0000 (10:34 -0400)] 
Merge branch 'tor-github/pr/1363'

6 years agoMerge branch 'maint-0.4.1'
Nick Mathewson [Wed, 2 Oct 2019 12:01:34 +0000 (08:01 -0400)] 
Merge branch 'maint-0.4.1'

6 years agoMerge branch 'maint-0.4.0' into maint-0.4.1
Nick Mathewson [Wed, 2 Oct 2019 12:01:34 +0000 (08:01 -0400)] 
Merge branch 'maint-0.4.0' into maint-0.4.1

6 years agoMerge branch 'maint-0.3.5' into maint-0.4.0
Nick Mathewson [Wed, 2 Oct 2019 12:01:34 +0000 (08:01 -0400)] 
Merge branch 'maint-0.3.5' into maint-0.4.0

6 years agoMerge branch 'maint-0.2.9' into maint-0.3.5
Nick Mathewson [Wed, 2 Oct 2019 12:01:33 +0000 (08:01 -0400)] 
Merge branch 'maint-0.2.9' into maint-0.3.5

6 years agoUpdate geoip and geoip6 to the October 1 2019 database.
Karsten Loesing [Wed, 2 Oct 2019 09:11:27 +0000 (11:11 +0200)] 
Update geoip and geoip6 to the October 1 2019 database.

6 years agolog: fix a typo in the function comment for log_fn_()
teor [Wed, 2 Oct 2019 02:12:26 +0000 (12:12 +1000)] 
log: fix a typo in the function comment for log_fn_()

Closes 31923.

6 years agoTravis: Allow the build to finish before the macOS Rust job
teor [Wed, 2 Oct 2019 00:09:02 +0000 (10:09 +1000)] 
Travis: Allow the build to finish before the macOS Rust job

When we merged TOR_RUST_VERSION from master, the allow_failures rule
did not match any more. Update it to make it match.

Closes 31859 for master.

6 years agoFix a crash bug in max_u16_in_sl()
Nick Mathewson [Tue, 1 Oct 2019 16:55:42 +0000 (12:55 -0400)] 
Fix a crash bug in max_u16_in_sl()

The documentation for this function says that the smartlist can
contain NULLs, but the code only handled NULLs if they were at the
start of the list.

We didn't notice this for a long time, because when Tor is run
normally, the sequence of msg_id_t is densely packed, and so this
list (mapping msg_id_t to channel_id_t) contains no NULL elements.
We could only run into this bug:
  * when Tor was running in embedded mode, and starting more than once.
  * when Tor ran first with more pubsub messages enabled, and then
    later with fewer.
  * When the second run (the one with fewer enabled pubsub messages)
    had at least some messages enabled, and those messages were not
    the ones with numerically highest msg_id_t values.

Fixes bug 31898; bugfix on 47de9c7b0a828de7fb8129413db70bc4e4ecac6d
in 0.4.1.1-alpha.

6 years agoAdd a test for max_u16_in_sl().
Nick Mathewson [Tue, 1 Oct 2019 16:52:13 +0000 (12:52 -0400)] 
Add a test for max_u16_in_sl().

This test does not currently pass, because of bug 31898.

6 years agoRename max_in_sl to max_in_u16_sl, and expose it as STATIC.
Nick Mathewson [Tue, 1 Oct 2019 16:42:26 +0000 (12:42 -0400)] 
Rename max_in_sl to max_in_u16_sl, and expose it as STATIC.

Since we want to make this function slightly more visible for testing
purposes, it needs a better name.

6 years agoMerge branch 'bug31859_041' into bug31859_master
teor [Tue, 1 Oct 2019 14:20:38 +0000 (00:20 +1000)] 
Merge branch 'bug31859_041' into bug31859_master

Merge master's RUST_VERSION="nightly" into the macOS Rust job
from bug31859_041.

Drop master's RUST_VERSION="beta", because we only have two
Rust jobs now.

6 years agoMerge branch 'bug31859_040' into bug31859_041
teor [Tue, 1 Oct 2019 13:50:24 +0000 (23:50 +1000)] 
Merge branch 'bug31859_040' into bug31859_041

Merge TOR_TEST_RNG_SEED in maint-0.4.1 into the coverage line
from bug31859_040.

6 years agoMerge branch 'bug31859_035' into bug31859_040
teor [Tue, 1 Oct 2019 13:46:28 +0000 (23:46 +1000)] 
Merge branch 'bug31859_035' into bug31859_040

6 years agoAdd comments to try to prevent recurrence of #31495.
Nick Mathewson [Tue, 1 Oct 2019 13:42:10 +0000 (09:42 -0400)] 
Add comments to try to prevent recurrence of #31495.

There is a bad design choice in two of our configuration types,
where the empty string encodes a value that is not the same as the
default value.  This design choice, plus an implementation mistake,
meant that config_dup() did not preserve the value of routerset_t,
and thereby caused bug #31495.

This comment-only patch documents the two types with the problem,
and suggests that implementors try to avoid it in the future.

Closes ticket 31907.

6 years agoTravis: Keep the macOS Rust job, but don't wait for it to finish
teor [Tue, 1 Oct 2019 07:32:46 +0000 (17:32 +1000)] 
Travis: Keep the macOS Rust job, but don't wait for it to finish

Since Rust on macOS is slow, don't wait for the macOS Rust job to finish.
Instead, split rust into slow rust (macOS) and fast rust (Linux). And
allow the build to finish before slow rust finishes.

Also make sure that we have:
* a Rust build on each platform,
* a Rust build with each compiler, and
* a check on all our Rust builds.

Finally, sort builds: allow fail last, macOS first, slowest first.

Closes 31859 for 0.3.5.

6 years agoHelp users who try to use v2 client auth in v3 onions.
George Kadianakis [Tue, 1 Oct 2019 10:40:04 +0000 (13:40 +0300)] 
Help users who try to use v2 client auth in v3 onions.

6 years agoImprove v3 client auth documentation in the man page.
George Kadianakis [Tue, 1 Oct 2019 10:39:34 +0000 (13:39 +0300)] 
Improve v3 client auth documentation in the man page.

6 years agoTravis: Split jobs, add essential jobs, remove redundant jobs
teor [Tue, 1 Oct 2019 07:28:26 +0000 (17:28 +1000)] 
Travis: Split jobs, add essential jobs, remove redundant jobs

Part of 31859 for 0.3.5.

6 years agoMerge branch 'bug31859_029' into bug31859_035
teor [Tue, 1 Oct 2019 07:20:16 +0000 (17:20 +1000)] 
Merge branch 'bug31859_029' into bug31859_035

While merging:
* leave out some redundant jobs and build matrix entries

6 years agoFix the documentation for GuardLifetime.
Nick Mathewson [Mon, 30 Sep 2019 18:50:57 +0000 (14:50 -0400)] 
Fix the documentation for GuardLifetime.

6 years agoTravis: Add a macOS chutney job, but don't wait for it to finish
teor [Thu, 26 Sep 2019 07:44:41 +0000 (17:44 +1000)] 
Travis: Add a macOS chutney job, but don't wait for it to finish

Since Travis macOS has IPv6 support (and Travis Linux does not), chutney
will now run its IPv6 networks as part of Travis CI.

But since chutney is slow, don't wait for the macOS chutney to finish.
(Travis have fixed the duplicate notification bug in fast_finish. So we
can use fast_finish and allow_failure to finish early. Unfortunately,
allow_failure also means we ignore failures in macOS chutney.)

Also make sure that we have:
* a compile on each platform, with each compiler,
* a check on each platform, and
* a check on each compiler.

Finally, sort builds: allow fail last, macOS first, slowest first.

Closes ticket 30860.
Closes ticket 31859 for 0.2.9.

6 years agoTravis: Remove a redundant clang Linux job
teor [Thu, 26 Sep 2019 07:39:46 +0000 (17:39 +1000)] 
Travis: Remove a redundant clang Linux job

Part of 31859.

6 years agoerr: Remove a duplicate header in backtrace.c
teor [Mon, 30 Sep 2019 13:13:32 +0000 (23:13 +1000)] 
err: Remove a duplicate header in backtrace.c

6 years agoerr: Always lock the backtrace buffer before it is used
teor [Mon, 30 Sep 2019 13:12:54 +0000 (23:12 +1000)] 
err: Always lock the backtrace buffer before it is used

Fixes bug 31734; bugfix on 0.2.5.3-alpha.

6 years agoRe-run "make autostyle" with improved annotate_ifdef_directives
Nick Mathewson [Mon, 30 Sep 2019 12:57:37 +0000 (08:57 -0400)] 
Re-run "make autostyle" with improved annotate_ifdef_directives

6 years agolog: When initialising log domain masks, only set known log domains
teor [Thu, 26 Sep 2019 03:37:06 +0000 (13:37 +1000)] 
log: When initialising log domain masks, only set known log domains

And add a runtime test that checks for unknown domains and flags.

Fixes bug 31854; bugfix on 0.2.1.1-alpha.

6 years agolog: Define count, boundary, and all macros for domains and flags
teor [Thu, 26 Sep 2019 03:33:17 +0000 (13:33 +1000)] 
log: Define count, boundary, and all macros for domains and flags

And do static checks on those macro definitions.

Part of 31854.

6 years agolog: Remove duplicate code and an outdated comment
teor [Thu, 26 Sep 2019 03:31:32 +0000 (13:31 +1000)] 
log: Remove duplicate code and an outdated comment

Preparation for 31854.

6 years agoMerge branch 'tor-github/pr/1366'
George Kadianakis [Mon, 30 Sep 2019 11:01:01 +0000 (14:01 +0300)] 
Merge branch 'tor-github/pr/1366'

6 years agoMerge branch 'tor-github/pr/1346'
George Kadianakis [Mon, 30 Sep 2019 10:56:51 +0000 (13:56 +0300)] 
Merge branch 'tor-github/pr/1346'

6 years agoMerge branch 'tor-github/pr/1302'
George Kadianakis [Mon, 30 Sep 2019 10:47:53 +0000 (13:47 +0300)] 
Merge branch 'tor-github/pr/1302'

6 years agoMerge branch 'tor-github/pr/1356'
George Kadianakis [Mon, 30 Sep 2019 10:47:06 +0000 (13:47 +0300)] 
Merge branch 'tor-github/pr/1356'

6 years agoMerge branch 'tor-github/pr/1339'
George Kadianakis [Mon, 30 Sep 2019 10:44:59 +0000 (13:44 +0300)] 
Merge branch 'tor-github/pr/1339'

6 years agoAppveyor: Avoid spurious errors in Appveyor CI builds
teor [Mon, 30 Sep 2019 05:14:21 +0000 (15:14 +1000)] 
Appveyor: Avoid spurious errors in Appveyor CI builds

When Appveyor fails before the install step, some of the finish step's
functions were not defined.

Fixes bug 31884; bugfix on 0.3.4.2-alpha.

6 years agotest: Avoid a map_anon_nofork test failure on SunOS
teor [Mon, 30 Sep 2019 04:54:56 +0000 (14:54 +1000)] 
test: Avoid a map_anon_nofork test failure on SunOS

This test failure happened due to a signed/unsigned integer
comparison.

This bug occurred on SunOS, it may also occur on other systems that
use signed char as the default. (And cast 1-byte integer constants
to an unsigned integer.)

Fixes bug 31897; bugfix on 0.4.1.1-alpha.

6 years agoannotate_ifdef_directives: test edge-case of 80-char line
Nick Mathewson [Fri, 27 Sep 2019 00:30:41 +0000 (20:30 -0400)] 
annotate_ifdef_directives: test edge-case of 80-char line

An 80-character line (79 characters if you don't count the newline)
should not be truncated, and should not have a "..." insterted.

6 years agoAnnotate_ifdef_directives: doctest for 80-column lines.
Nick Mathewson [Thu, 26 Sep 2019 23:57:41 +0000 (19:57 -0400)] 
Annotate_ifdef_directives: doctest for 80-column lines.

6 years agoRename annotate_ifdef_directives to end with .py.
Nick Mathewson [Thu, 26 Sep 2019 19:43:40 +0000 (15:43 -0400)] 
Rename annotate_ifdef_directives to end with .py.

This allows the python doctest module to process it correctly
when invoked as:
   python -m doctest -v annotate_ifdef_directives.py

6 years agoannotate_ifdef_directives: Allow it to be imported as a module.
Nick Mathewson [Thu, 26 Sep 2019 19:36:20 +0000 (15:36 -0400)] 
annotate_ifdef_directives: Allow it to be imported as a module.

6 years agoUse Doctests to test the behavior of annotate_ifdef_directives.
Nick Mathewson [Thu, 26 Sep 2019 14:03:28 +0000 (10:03 -0400)] 
Use Doctests to test the behavior of annotate_ifdef_directives.

6 years agoannotate_ifdef_directives: generate paren-balanced expressions
Nick Mathewson [Thu, 26 Sep 2019 01:27:17 +0000 (21:27 -0400)] 
annotate_ifdef_directives: generate paren-balanced expressions

This algorithm is not fully general, but it strikes a balance
between efficiency, simplicity, and correctness.

6 years agoannotate_ifdef_directives: clarify situation with newlines
Nick Mathewson [Thu, 26 Sep 2019 01:13:30 +0000 (21:13 -0400)] 
annotate_ifdef_directives: clarify situation with newlines

Our line limit is 80 characters, assuming that there is a single
terminating newline character that counts towards the limit.  On
Windows, this might go as high as 81 characters, if we count CRLF as
two characters.

6 years agoRun "make autostyle" with new "annotate_ifdef_directives"
Nick Mathewson [Wed, 18 Sep 2019 15:01:12 +0000 (11:01 -0400)] 
Run "make autostyle" with new "annotate_ifdef_directives"

6 years agoChanges file for 31759 and 31779
Nick Mathewson [Wed, 18 Sep 2019 15:06:54 +0000 (11:06 -0400)] 
Changes file for 31759 and 31779

6 years agoannotate_ifdef_directives: remove some cases of double negation
Nick Mathewson [Wed, 18 Sep 2019 14:59:35 +0000 (10:59 -0400)] 
annotate_ifdef_directives: remove some cases of double negation

This change should reduce the number of cases where we say
"/* !(!defined(foo)) */" .

This only does cases where we can use a regex to make sure that the
simplification is guaranteed to be correct.  Full boolean
simplification would require this script to parse C, and nobody
wants that.

6 years agoMerge remote-tracking branch 'tor-github/pr/1308'
Nick Mathewson [Thu, 26 Sep 2019 18:36:37 +0000 (14:36 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1308'

6 years agoTravis: Unroll the build matrix into matrix: include:
teor [Thu, 26 Sep 2019 07:25:17 +0000 (17:25 +1000)] 
Travis: Unroll the build matrix into matrix: include:

The jobs should be the same, but Travis may display them differently.

Part of 31859.

6 years agolock: Avoid some undefined behaviour when freeing mutexes.
teor [Fri, 20 Sep 2019 01:27:05 +0000 (11:27 +1000)] 
lock: Avoid some undefined behaviour when freeing mutexes.

Fixes bug 31736; bugfix on 0.0.7.

6 years agolog: explain why it is safe to leave the log mutex initialized
teor [Thu, 26 Sep 2019 02:18:23 +0000 (12:18 +1000)] 
log: explain why it is safe to leave the log mutex initialized

The log mutex is dynamically initialized, guarded by log_mutex_initialized.
We don't want to destroy it, because after it is destroyed, we won't see
any more logs.

If tor is re-initialized, log_mutex_initialized will still be 1. So we
won't trigger any undefined behaviour by trying to re-initialize the
log mutex.

Part of 31736, but committed in this branch to avoid merge conflicts.

6 years agosandbox: Allow backtrace signals to be disabled
teor [Tue, 24 Sep 2019 03:51:38 +0000 (13:51 +1000)] 
sandbox: Allow backtrace signals to be disabled

Part of 31614.

6 years agochanges: file for 31614
teor [Thu, 26 Sep 2019 02:09:56 +0000 (12:09 +1000)] 
changes: file for 31614

6 years agobacktrace: avoid undefined behaviour on re-initialisation
teor [Fri, 20 Sep 2019 01:40:05 +0000 (11:40 +1000)] 
backtrace: avoid undefined behaviour on re-initialisation

cb_buf_mutex is statically initialised, so we can not destroy it when
we are shutting down the err subsystem. If we destroy it, and then
re-initialise tor, all our backtraces will fail.

Part of 31736, but committed in this branch to avoid merge conflicts.

6 years agoMerge remote-tracking branch 'tor-github/pr/1349'
Nick Mathewson [Wed, 25 Sep 2019 17:07:19 +0000 (13:07 -0400)] 
Merge remote-tracking branch 'tor-github/pr/1349'

6 years agoMerge branch 'tor-github/pr/1337'
George Kadianakis [Wed, 25 Sep 2019 11:19:49 +0000 (14:19 +0300)] 
Merge branch 'tor-github/pr/1337'