summaryrefslogtreecommitdiff
path: root/server/dispatch.c
diff options
context:
space:
mode:
authorGravatar John Kohl <jtkohl@mit.edu>1988-06-28 14:14:55 +0000
committerGravatar John Kohl <jtkohl@mit.edu>1988-06-28 14:14:55 +0000
commit8d4c68242353d0acdeddebb2ca4278b0069dc1d4 (patch)
treec0c882c57027539a93ae214eb1c4475b906ff55d /server/dispatch.c
parentff6ad002d7db0b11e61f7943b3aa3436bedd0d94 (diff)
use symbolic names for authentication flag
Diffstat (limited to 'server/dispatch.c')
-rw-r--r--server/dispatch.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/server/dispatch.c b/server/dispatch.c
index 448e7f4..5f653a5 100644
--- a/server/dispatch.c
+++ b/server/dispatch.c
@@ -155,14 +155,18 @@ handle_packet()
input_sin.sin_family = AF_INET;
authentic = ZCheckAuthentication(&new_notice,
&input_sin);
- if (authentic == -1)
- authentic = 0; /* -1 means Kerberos check failed */
- }
- else {
+
+
+ } else
authentic = ZCheckAuthentication(&new_notice,
&whoisit);
- if (authentic == -1)
- authentic = 0;
+ switch (authentic) {
+ ZAUTH_FAILED:
+ ZAUTH_NO:
+ authentic = 0;
+ break;
+ ZAUTH_YES:
+ authentic = 1;
}
if (whoisit.sin_port != hm_port &&
strcmp(new_notice.z_class,ZEPHYR_ADMIN_CLASS) &&