summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Goulet <dgoulet@torproject.org>2019-04-24 09:43:28 -0400
committerDavid Goulet <dgoulet@torproject.org>2019-04-24 09:43:28 -0400
commit4b599aaae4fc33460553306a8bba41d777558420 (patch)
treed01ff1863ea1cc8e00cc99af2811f290805c00c9
parent4587e67dfd29f62ced4c52c18d2c2b7e1538080b (diff)
parentcdafcc49bc273e472d40ea8c01219bbc165c92cb (diff)
downloadtor-4b599aaae4fc33460553306a8bba41d777558420.tar.gz
tor-4b599aaae4fc33460553306a8bba41d777558420.zip
Merge branch 'tor-github/pr/939'
-rw-r--r--changes/bug301515
-rw-r--r--src/tools/tor-resolve.c1
2 files changed, 6 insertions, 0 deletions
diff --git a/changes/bug30151 b/changes/bug30151
new file mode 100644
index 0000000000..8ac9a320a0
--- /dev/null
+++ b/changes/bug30151
@@ -0,0 +1,5 @@
+ o Minor bugfixes (tor-resolve):
+ - Fix a memory leak in tor-resolve that could happen if Tor gave it a
+ malformed SOCKS response. (Memory leaks in tor-resolve don't actually
+ matter, but it's good to fix them anyway.) Fixes bug 30151; bugfix on
+ 0.4.0.1-alpha.
diff --git a/src/tools/tor-resolve.c b/src/tools/tor-resolve.c
index 98b3a4a74c..5d97696c18 100644
--- a/src/tools/tor-resolve.c
+++ b/src/tools/tor-resolve.c
@@ -424,6 +424,7 @@ do_resolve(const char *hostname,
if (parsed < 2) {
log_err(LD_NET, "Failed to parse SOCKS5 method selection "
"message");
+ socks5_server_method_free(m);
goto err;
}