]> andersk Git - moira.git/blobdiff - update/update_server.c
sms -> moira
[moira.git] / update / update_server.c
index d4ab26d2a1fd0adc3019c867dcac02ee7b013280..7be11608f46f9e96024abd59e24e17b11242c6f2 100644 (file)
@@ -2,24 +2,24 @@
  *     $Source$
  *     $Header$
  */
+/*  (c) Copyright 1988 by the Massachusetts Institute of Technology. */
+/*  For copying and distribution information, please see the file */
+/*  <mit-copyright.h>. */
 
 #ifndef lint
 static char *rcsid_dispatch_c = "$Header$";
 #endif lint
 
+#include <mit-copyright.h>
 #include <stdio.h>
 #include <gdb.h>
 #include <errno.h>
 #include <strings.h>
-#include <sms.h>
+#include <moira.h>
 #include <sys/file.h>
 #include <sys/ioctl.h>
 #include "update.h"
 
-/* XXX */
-#include "kludge.h"
-/* XXX */
-
 extern int auth_001(), inst_001();
 extern int xfer_002(), exec_002();
 
@@ -65,7 +65,7 @@ err(code, fmt)
      char *fmt;
 {
      sprintf(buf, fmt, error_message(code));
-     sms_log_error(buf);
+     mr_log_error(buf);
 }
 
 main(argc, argv)
@@ -96,7 +96,7 @@ main(argc, argv)
 #ifndef DEBUG
      if (fork())
        exit(0);
-     n = open("/dev/tty", O_RDWR|O_NDELAY);
+     n = open("/dev/tty", O_RDWR|FNDELAY);
      if (n > 0) {
         (void) ioctl(n, TIOCNOTTY, (char *)NULL);
         (void) close(n);
@@ -104,9 +104,9 @@ main(argc, argv)
 #endif
 
      umask(0022);
-     init_sms_err_tbl();
-     init_krb_err_tbl();
-     sms_update_initialize();
+     initialize_sms_error_table();
+     initialize_krb_error_table();
+     mr_update_initialize();
 
      /* wait for connection */
      gdb_init();
@@ -120,7 +120,7 @@ main(argc, argv)
         exit(1);
      }
 
-     sms_log_info("got connection");
+     mr_log_info("got connection");
      /* got a connection; loop forever */
      while (1) {
          register char *cp;
@@ -145,8 +145,8 @@ main(argc, argv)
              }
          }
          sprintf(buf, "unknown request received: %s\n", STRING_DATA(str));
-         sms_log_error(buf);
-         code = send_int(SMS_UNKNOWN_PROC);
+         mr_log_error(buf);
+         code = send_int(MR_UNKNOWN_PROC);
          if (code) {
              err(connection_errno(conn), "%s: sending UNKNOWN_PROC");
          }
@@ -183,7 +183,7 @@ initialize()
  * any arguments are ignored
  *
  * function:
- *     closes connection from SMS
+ *     closes connection from MR
  */
 int
 quit(str)
@@ -194,7 +194,7 @@ quit(str)
 #endif /* lint */
      (void) send_ok();
      sever_connection(conn);
-     sms_log_info("Closing connection.");
+     mr_log_info("Closing connection.");
      exit(0);
 }
 
@@ -209,7 +209,7 @@ lose(msg)
     char *msg;
 {
     sprintf(buf, "%s: %s", error_message(code), msg);
-    sms_log_error(buf);
+    mr_log_error(buf);
     if (conn)
        sever_connection(conn);
     exit(1);
This page took 0.078325 seconds and 4 git commands to generate.