]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Replace magic values in rlm_pap.c with symbolic constants (#4832)
authorHerwin <herwin@snt.utwente.nl>
Fri, 30 Dec 2022 15:47:25 +0000 (16:47 +0100)
committerGitHub <noreply@github.com>
Fri, 30 Dec 2022 15:47:25 +0000 (10:47 -0500)
src/modules/rlm_pap/rlm_pap.c

index 318e9a806eeee15f7cd7c06d539d4d4da6f1daee..5fc6877dceb22ad8d442e063565009c870a0a2aa 100644 (file)
@@ -479,8 +479,8 @@ static rlm_rcode_t CC_HINT(nonnull) mod_authorize(void *instance, REQUEST *reque
                         *      Auth-Type := Accept
                         *      Auth-Type := Reject
                         */
-                       if ((vp->vp_integer == 254) ||
-                           (vp->vp_integer == 4)) {
+                       if ((vp->vp_integer == PW_AUTH_TYPE_ACCEPT) ||
+                           (vp->vp_integer == PW_AUTH_TYPE_REJECT)) {
                            found_pw = true;
                        }
                        break;