[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [obfsproxy/master] Fixed memory leak when incorrect arguments are given. Fixes bug5068.
commit 79c44ced73a77ba045473c0fd2c8015a064e10ae
Author: Brendan C <temurion@xxxxxxxxx>
Date: Sun Feb 12 12:26:38 2012 -0600
Fixed memory leak when incorrect arguments are given. Fixes bug5068.
---
src/external.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/src/external.c b/src/external.c
index 3a79909..76abf56 100644
--- a/src/external.c
+++ b/src/external.c
@@ -56,8 +56,10 @@ launch_external_proxy(const char *const *begin)
usage();
} else {
config_t *cfg = config_create(end - begin, begin);
- if (!cfg)
+ if (!cfg) {
+ smartlist_free(configs);
return -1; /* diagnostic already issued */
+ }
smartlist_add(configs, cfg);
}
begin = end;
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits