George Kadianakis
fc760c5088
Merge branch 'tor-github/pr/1356'
2019-09-30 13:47:06 +03:00
George Kadianakis
4673cb8168
Merge branch 'tor-github/pr/1339'
2019-09-30 13:44:59 +03:00
Nick Mathewson
fc1134e3e5
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.
2019-09-27 21:04:22 -04:00
Nick Mathewson
21c9f7c85e
Annotate_ifdef_directives: doctest for 80-column lines.
2019-09-27 21:04:22 -04:00
Nick Mathewson
f1e0665c93
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
2019-09-27 21:04:22 -04:00
Nick Mathewson
d229399e77
annotate_ifdef_directives: Allow it to be imported as a module.
2019-09-27 21:04:22 -04:00
Nick Mathewson
6f0e697e41
Use Doctests to test the behavior of annotate_ifdef_directives.
2019-09-27 21:04:22 -04:00
Nick Mathewson
195aa2f5f7
annotate_ifdef_directives: generate paren-balanced expressions
...
This algorithm is not fully general, but it strikes a balance
between efficiency, simplicity, and correctness.
2019-09-27 21:04:22 -04:00
Nick Mathewson
21cc9d13f3
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.
2019-09-26 15:52:45 -04:00
Nick Mathewson
194dbea24d
Run "make autostyle" with new "annotate_ifdef_directives"
2019-09-26 15:52:45 -04:00
Nick Mathewson
3283fd7e79
Changes file for 31759 and 31779
2019-09-26 15:52:45 -04:00
Nick Mathewson
65e63e7461
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.
2019-09-26 15:52:45 -04:00
Nick Mathewson
ffd857bbe1
Merge remote-tracking branch 'tor-github/pr/1308'
2019-09-26 14:36:37 -04:00
Nick Mathewson
40a22fb707
Merge remote-tracking branch 'tor-github/pr/1349'
2019-09-25 13:07:19 -04:00
George Kadianakis
7157d80c6f
Merge branch 'tor-github/pr/1337'
2019-09-25 14:19:49 +03:00
George Kadianakis
01a797be4e
Merge branch 'tor-github/pr/1334'
2019-09-25 14:19:02 +03:00
George Kadianakis
0a77e5f1c2
Merge branch 'tor-github/pr/1341'
2019-09-25 14:18:15 +03:00
George Kadianakis
09769779a0
Merge branch 'tor-github/pr/1357'
2019-09-25 14:17:35 +03:00
George Kadianakis
6677eae579
Merge branch 'tor-github/pr/1355'
2019-09-25 14:17:03 +03:00
George Kadianakis
6712fb9e27
Merge branch 'tor-github/pr/1353'
2019-09-25 14:16:28 +03:00
George Kadianakis
2199629648
Merge branch 'tor-github/pr/1345'
2019-09-25 14:14:30 +03:00
George Kadianakis
e77ad795c6
Merge branch 'tor-github/pr/1322'
2019-09-25 14:13:44 +03:00
George Kadianakis
99f75373de
Merge branch 'tor-github/pr/1309'
2019-09-25 14:12:42 +03:00
teor
d30a042fa8
test: Use SEVERITY_MASK_IDX() to find the LOG_* mask indexes
...
In the unit tests and fuzzers.
Fixes bug 31334; bugfix on 0.2.5.2-alpha.
2019-09-25 16:40:09 +10:00
teor
1ad1e84b17
log: Move SEVERITY_MASK_IDX() to log.h
...
Move SEVERITY_MASK_IDX() to log.h private/unit tests section, so that
we can use it in log.c, the unit tests, and the fuzzers.
(The test and fuzzer code changes are in a subsequent commit.)
Preparation for bug 31334.
2019-09-25 16:37:07 +10:00
teor
0c07cd24d4
changes: file for 31839
2019-09-24 15:22:57 +10:00
teor
0cb57a4908
feature/control: add a missing word to the send_control_done() comment
2019-09-24 15:08:37 +10:00
teor
dfea789203
log: Improve the documentation for tor_log_update_sigsafe_err_fds()
...
Part of 31839.
2019-09-24 15:04:03 +10:00
teor
102546f99f
doc: Document the signal-safe log behaviour in the tor man page
...
Part of 31389.
2019-09-24 15:03:17 +10:00
teor
22c33ea7f7
practracker: Fix a typo in the usage message
...
Fixes bug 31828; bugfix on 0.4.2.1-alpha.
2019-09-24 14:37:43 +10:00
teor
c7c849bba8
configure: Explain --disable-module-dirauth better
...
Explain what the optional Directory Authority module is, and what
happens when it is disabled.
Fixes bug 31825; bugfix on 0.3.4.1-alpha.
2019-09-24 11:29:22 +10:00
teor
83fa962c1a
test: a file with no config options, at the end of an %include directory
...
(The file must contain whitespace or comments to trigger the bug.)
Regression test for 31408.
2019-09-24 11:10:50 +10:00
teor
876b3e2775
Merge branch 'bug31408_035' into bug31408_master
2019-09-24 11:07:38 +10:00
teor
0614f83905
changes: use correct bugfix release, and reword changes file for 31408
2019-09-24 11:06:20 +10:00
Roger Dingledine
e1429d9148
fix typo in comment
2019-09-23 18:32:05 -04:00
AmreshVenugopal
3e45260594
fix: Ticket #31589
...
- The function `decrypt_desc_layer` has a cleaner interface.
- `is_superencrypted_layer` changed from `int` -> `bool`
[ticket details](https://trac.torproject.org/projects/tor/ticket/31589 )
add(changes/*): changes file
fix(src/features/hs): is_superencrypted changed from `int` -> `bool`
fix(changes/ticket31589): header
add(changes/ticket31589): subsystem(onion services) to change
2019-09-23 23:52:01 +05:30
Nick Mathewson
16890839d3
annotate_ifdef_directives: obey an 80-column line-limit
...
If we would add a comment making a line longer than 80 columns,
instead truncate the variable portion of the comment until it just
fits into 80 columns, with an ellipsis.
2019-09-23 08:48:53 -04:00
Nick Mathewson
f36e743e5d
annotate_ifdef_directives: introduce a function to make commented lines
...
No functional change in this commit.
2019-09-23 08:48:53 -04:00
Nick Mathewson
0b367f3386
Add comments to annotate_ifdef_directives
2019-09-23 08:48:53 -04:00
Daniel Pinto
15490816da
Fix bug when %including folder with comment only files. #31408
...
When processing a %included folder, a bug caused the pointer to
the last element of the options list to be set to NULL when
processing a file with only comments or whitepace. This could
cause options from other files on the same folder to be
discarded depending on the lines after the affected %include.
2019-09-23 10:39:08 +10:00
Nick Mathewson
c309169217
microdesc_parse: convert some ints to bools
...
Noted by ahf during review of #31675
2019-09-19 14:37:24 -04:00
Nick Mathewson
6100378c29
changes file for microdesc_parse refactoring.
2019-09-19 14:37:24 -04:00
Nick Mathewson
2e1989dacc
Remove practracker exception for microdesc parsing function
2019-09-19 14:37:24 -04:00
Nick Mathewson
194884977c
microdesc_parse: Rename "next" label to "err".
2019-09-19 14:37:24 -04:00
Nick Mathewson
2094796c24
Reindent microdesc_parse_fields().
...
I suggest reviewing this with -b: it should be whitespace-only.
2019-09-19 14:37:24 -04:00
Nick Mathewson
ec368409fa
Extract field-parsing code for microdesc_parse.c
...
The code here parses the fields from the microdescriptor, including
possible annotations, and stores them into a microdesc_t object.
This commit is almost pure code movement; I recommend using
--color-moved to review it.
2019-09-19 14:37:24 -04:00
Nick Mathewson
b1552e8814
Reindent microdesc_extract_body().
...
This commit is whitespace-only; I suggest reviewing with -b.
2019-09-19 14:37:24 -04:00
Nick Mathewson
9cbc166ea0
Extract the body-copying portion of microdesc parsing
...
This code is logically independent of the rest of the function, and
goes better in its own function.
This is almost purely code movement; I suggest reviewing with
--color-moved.
2019-09-19 14:37:24 -04:00
Nick Mathewson
e6c5b248ae
Merge branch 'maint-0.4.1'
...
"ours" to avoid version bump
2019-09-19 08:52:42 -04:00
Nick Mathewson
6f3f93d86c
bump to 0.4.1.6-dev
2019-09-19 08:52:15 -04:00