]> andersk Git - moira.git/commitdiff
catch deadlock errors
authormar <mar>
Fri, 1 Sep 1989 13:12:43 +0000 (13:12 +0000)
committermar <mar>
Fri, 1 Sep 1989 13:12:43 +0000 (13:12 +0000)
reg_svr/reg_svr.c

index ebc45d5ffafb6be5cb156a03e68122df84c8e5c0..b7bd0029f8abea058fd069f254ddae4c7c2df3b8 100644 (file)
@@ -561,6 +561,9 @@ int reserve_user(message,retval)
          case SMS_IN_USE:
            status = UREG_LOGIN_USED;
            break;
+         case SMS_DEADLOCK:
+           status = UREG_MISC_ERROR;
+           break;
          default:
            critical_alert(FAIL_INST,"%s returned from register_user.",
                           error_message(status));
@@ -610,10 +613,13 @@ struct msg *message;
     q_argv[0] = login;
     q_argv[1] = state;
     if ((status = sms_query(q_name, q_argc, q_argv, null_callproc,
-                           (char *)0)) != SMS_SUCCESS)
-       critical_alert(FAIL_INST,"%s returned from update_user_status.",
-                      error_message(status));
-    
+                           (char *)0)) != SMS_SUCCESS) {
+       if (status == SMS_DEADLOCK)
+         status = UREG_MISC_ERROR;
+       else
+         critical_alert(FAIL_INST,"%s returned from update_user_status.",
+                        error_message(status));
+    }
     com_err(whoami,status," returned from set_final_status");
     return status;
 }
@@ -750,6 +756,9 @@ char *retval;
          case SMS_IN_USE:
            status = UREG_LOGIN_USED;
            break;
+         case SMS_DEADLOCK:
+           status = UREG_MISC_ERROR;
+           break;
          default:
            critical_alert(FAIL_INST,"%s returned from update_user.",
                           error_message(status));
This page took 0.030487 seconds and 5 git commands to generate.