summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-12-18 13:52:36 -0500
committerNick Mathewson <nickm@torproject.org>2018-12-18 13:52:36 -0500
commit702fd6f0f21138c0864cdf0ce73c0319aceeccb7 (patch)
tree70046a372fabd9376960c6dbd666e513056d5281
parentbf71dce01a9977786a6ba1e99fe8827c08df57e5 (diff)
parent4894d44ab8beee587c99a1765236813d445b392e (diff)
downloadtor-702fd6f0f21138c0864cdf0ce73c0319aceeccb7.tar.gz
tor-702fd6f0f21138c0864cdf0ce73c0319aceeccb7.zip
Merge branch 'ticket28881_035' into maint-0.3.5
-rw-r--r--changes/ticket288814
-rw-r--r--src/app/config/config.c2
2 files changed, 6 insertions, 0 deletions
diff --git a/changes/ticket28881 b/changes/ticket28881
new file mode 100644
index 0000000000..1b015a6c37
--- /dev/null
+++ b/changes/ticket28881
@@ -0,0 +1,4 @@
+ o Code simplification and refactoring:
+ - When parsing a port configuration, make it more
+ obvious to static analyzer tools that we will always initialize the
+ address. Closes ticket 28881.
diff --git a/src/app/config/config.c b/src/app/config/config.c
index 81cc3e378f..4a8f94da0e 100644
--- a/src/app/config/config.c
+++ b/src/app/config/config.c
@@ -6913,6 +6913,8 @@ parse_port_config(smartlist_t *out,
for (; ports; ports = ports->next) {
tor_addr_t addr;
+ tor_addr_make_unspec(&addr);
+
int port;
int sessiongroup = SESSION_GROUP_UNSET;
unsigned isolation = ISO_DEFAULT;