mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2025-02-23 14:40:51 +01:00
fix a seg fault on hup when FascistFirewall is defined
svn:r2294
This commit is contained in:
parent
8ddc029d07
commit
cf6159abb9
1 changed files with 3 additions and 2 deletions
|
@ -548,6 +548,7 @@ static void free_options(or_options_t *options) {
|
|||
if (options->FirewallPorts) {
|
||||
SMARTLIST_FOREACH(options->FirewallPorts, char *, cp, tor_free(cp));
|
||||
smartlist_free(options->FirewallPorts);
|
||||
options->FirewallPorts = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -800,8 +801,8 @@ int getconfig(int argc, char **argv, or_options_t *options) {
|
|||
|
||||
if(options->FascistFirewall && !options->FirewallPorts) {
|
||||
options->FirewallPorts = smartlist_create();
|
||||
smartlist_add(options->FirewallPorts, "80");
|
||||
smartlist_add(options->FirewallPorts, "443");
|
||||
smartlist_add(options->FirewallPorts, tor_strdup("80"));
|
||||
smartlist_add(options->FirewallPorts, tor_strdup("443"));
|
||||
}
|
||||
if(options->FirewallPorts) {
|
||||
SMARTLIST_FOREACH(options->FirewallPorts, const char *, cp,
|
||||
|
|
Loading…
Add table
Reference in a new issue