summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinus Nordberg <linus@nordu.net>2016-11-01 15:09:41 +0100
committerLinus Nordberg <linus@nordu.net>2016-11-01 15:09:41 +0100
commit829c65af8e4eee61168f3499c8fb23d458dbf0d3 (patch)
tree9deeea3bd58ec3f5ce9243d5004675b51ab228ee
parent98d7bbe9214488d595031257b35bc5abb5a24f43 (diff)
Revert partial fix for RADSECPROXY-69 (98d7bbe).
This was potentially making things worse.
-rw-r--r--develdoc.txt4
-rw-r--r--radsecproxy.c5
2 files changed, 5 insertions, 4 deletions
diff --git a/develdoc.txt b/develdoc.txt
index d61dab6..fb43cd0 100644
--- a/develdoc.txt
+++ b/develdoc.txt
@@ -337,8 +337,8 @@ traverses the list of realms and for each realm:
- same thing for realm->accsrvconfs as for srvconfs
- - if none of realm->srvconfs->servers and realm->accsrvonfs->servers
- have dynamiclookuparg set:
+ - if none of the realm->srvconfs nor the realm->accsrvonfs has a
+ dynamiclookupcommand:
- for each srv in realm->srvconfs: free srv and decrease ref on realm
diff --git a/radsecproxy.c b/radsecproxy.c
index 2f21fcb..4e4caad 100644
--- a/radsecproxy.c
+++ b/radsecproxy.c
@@ -706,7 +706,7 @@ int hasdynamicserver(struct list *srvconfs) {
struct list_node *entry;
for (entry = list_first(srvconfs); entry; entry = list_next(entry))
- if (((struct clsrvconf *)entry->data)->servers->dynamiclookuparg)
+ if (((struct clsrvconf *)entry->data)->dynamiclookupcommand)
return 1;
return 0;
}
@@ -1899,13 +1899,14 @@ void *clientwr(void *arg) {
}
}
errexit:
- conf->servers = NULL;
if (server->dynamiclookuparg) {
removeserversubrealms(realms, conf);
if (dynconffail)
free(conf);
else
freeclsrvconf(conf);
+ } else {
+ conf->servers = NULL;
}
freeserver(server, 1);
return NULL;