summaryrefslogtreecommitdiff
path: root/radsecproxy.c
diff options
context:
space:
mode:
Diffstat (limited to 'radsecproxy.c')
-rw-r--r--radsecproxy.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/radsecproxy.c b/radsecproxy.c
index 2276d40..f026fee 100644
--- a/radsecproxy.c
+++ b/radsecproxy.c
@@ -2417,10 +2417,12 @@ struct modattr *extractmodattr(char *nameval) {
struct rewrite *getrewrite(char *alt1, char *alt2) {
struct rewrite *r;
- if ((r = hash_read(rewriteconfs, alt1, strlen(alt1))))
- return r;
- if ((r = hash_read(rewriteconfs, alt2, strlen(alt2))))
- return r;
+ if (alt1)
+ if ((r = hash_read(rewriteconfs, alt1, strlen(alt1))))
+ return r;
+ if (alt2)
+ if ((r = hash_read(rewriteconfs, alt2, strlen(alt2))))
+ return r;
return NULL;
}