[fixes #176] Shouldn't return if we fail to create the auth-type because the reject...
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Sun, 27 Jan 2013 00:17:42 +0000 (16:17 -0800)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Sun, 27 Jan 2013 00:17:57 +0000 (16:17 -0800)
src/main/process.c

index 53166e9..8167e76 100644 (file)
@@ -1771,14 +1771,15 @@ static int process_proxy_reply(REQUEST *request)
        if (!vp && request->proxy_reply &&
            request->proxy_reply->code == PW_AUTHENTICATION_REJECT) {
                DICT_VALUE      *dval;
-       
+
                dval = dict_valbyname(PW_POST_PROXY_TYPE, 0, "Reject");
-               if (!dval) return 0;
-                       
-               vp = radius_paircreate(request, &request->config_items,
-                                      PW_POST_PROXY_TYPE, 0, PW_TYPE_INTEGER);
+               if (dval) {
+                       vp = radius_paircreate(request, &request->config_items,
+                                              PW_POST_PROXY_TYPE, 0,
+                                              PW_TYPE_INTEGER);
 
-               vp->vp_integer = dval->value;
+                       vp->vp_integer = dval->value;
+               }
        }
        
        if (vp) {