From d3f504555a7bde9d3bbf5b89b3efb5cb7c11dfc2 Mon Sep 17 00:00:00 2001 From: Herwin Weststrate Date: Fri, 23 Oct 2015 15:12:37 +0200 Subject: [PATCH] Fixed usage os Post-Auth-Type REJECT The values had been shifted in the dictionaries in commit d9a9d594e666d70b9762c879c2c69d9a9bb38a64, but this piece of code used a hardcoded magic value instead of the autogenerated constant from include/attributes.h. Fix this by using the constant. --- src/main/auth.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/main/auth.c b/src/main/auth.c index 10a0a3e..4c8fb3c 100644 --- a/src/main/auth.c +++ b/src/main/auth.c @@ -327,13 +327,12 @@ int rad_postauth(REQUEST *request) /* * We WERE going to have a nice reply, but * something went wrong. So we've got to run - * Post-Auth-Type Reject, which is defined in the - * dictionaries as having value "1". + * Post-Auth-Type Reject. */ if (request->reply->code != PW_CODE_ACCESS_REJECT) { RDEBUG("Using Post-Auth-Type Reject"); - process_post_auth(1, request); + process_post_auth(PW_POST_AUTH_TYPE_REJECT, request); } fr_state_discard(request, request->packet); -- 2.1.4