]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
swap error condition so that it's correct
authorAlan T. DeKok <aland@freeradius.org>
Sat, 21 Jun 2025 11:27:40 +0000 (07:27 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Sat, 21 Jun 2025 11:28:39 +0000 (07:28 -0400)
arguably we should also print out the error name, too.  But that's
a bit more work, so we leave it for later

src/modules/rlm_eap/types/rlm_eap_teap/eap_teap.c

index b96b7de5ca510da482475682698a7156a37a88ff..e85404b846fb9e6d0be46d6ce4d6933ac5a5b668 100644 (file)
@@ -530,10 +530,10 @@ unexpected:
         */
        if (status) {
                if (status == EAP_TEAP_TLV_RESULT_FAILURE) {
-                       if (!error) {
+                       if (error) {
                                REDEBUG("Phase 2: Received Result TLV from peer which indicates failure with error %u.  Rejecting request.", error);
                        } else {
-                               REDEBUG("Phase 2: Received Result from peer which indicates failure.  Rejecting request.");
+                               REDEBUG("Phase 2: Received Result TLV from peer which indicates failure.  Rejecting request.");
                        }
                        return 0;
                }