]> andersk Git - moira.git/commitdiff
get errorcode from set_krb_mapping()
authormar <mar>
Wed, 28 Mar 1990 15:27:25 +0000 (15:27 +0000)
committermar <mar>
Wed, 28 Mar 1990 15:27:25 +0000 (15:27 +0000)
server/mr_sauth.c

index 45b34a181537a6180dcffc9b7a5ce62032aace01..c27ec9452b0fc67580398c1383709b3c46c8250e 100644 (file)
@@ -77,8 +77,8 @@ do_auth(cl)
        else
          ok = 0;
        /* this is in a separate function because it accesses the database */
-       set_krb_mapping(cl->clname, ad.pname, ok,
-                       &cl->client_id, &cl->users_id);
+       status = set_krb_mapping(cl->clname, ad.pname, ok,
+                                &cl->client_id, &cl->users_id);
 
        if (cl->args->mr_version_no == MR_VERSION_2) {
            bcopy(cl->args->mr_argv[1], cl->entity, 8);
@@ -91,7 +91,9 @@ do_auth(cl)
        if (log_flags & LOG_RES)
            com_err(whoami, 0, "Auth to %s using %s, uid %d cid %d",
                    cl->clname, cl->entity, cl->users_id, cl->client_id);
-       if (cl->users_id == 0)
+       if (status != MR_SUCCESS)
+         cl->reply.mr_status = status;
+       else if (cl->users_id == 0)
          cl->reply.mr_status = MR_USER_AUTH;
 }
 
This page took 0.112065 seconds and 5 git commands to generate.