]> andersk Git - moira.git/blobdiff - lib/mr_param.c
renamed sms_do_update.c to sms_ops.c
[moira.git] / lib / mr_param.c
index 45bd66c9f08a244c671731ccfd66dbf471cfddcb..b267382f60d2b161932e57969d69ec525a4611d7 100644 (file)
@@ -4,29 +4,16 @@
  *     $Header$
  *
  *     Copyright (C) 1987 by the Massachusetts Institute of Technology
+ *     For copying and distribution information, please see the file
+ *     <mit-copyright.h>.
  *
- *     $Log$
- *     Revision 1.2  1987-08-02 21:49:15  wesommer
- *     Clean up error handling, memory handling.
- *
- * Revision 1.1  87/06/16  17:48:21  wesommer
- * Initial revision
- * 
- * Revision 1.4  87/06/04  01:32:18  wesommer
- * Renamed gdb calls.
- * 
- * Revision 1.3  87/06/01  03:33:54  wesommer
- * Added destroy_reply.
- * 
- * Revision 1.2  87/05/31  22:03:37  wesommer
- * Fixed numerous bugs; still shaky.
- * 
  */
 
 #ifndef lint
 static char *rcsid_sms_param_c = "$Header$";
 #endif lint
 
+#include <mit-copyright.h>
 #include <sys/types.h>
 #include <netinet/in.h>
 #include "sms_private.h"
@@ -114,7 +101,7 @@ sms_start_send(op, hcon, arg)
      */
 
     ((long *)buf)[0] = htonl(sms_size);
-    ((long *)buf)[1] = htonl((u_int)SMS_VERSION_1);
+    ((long *)buf)[1] = htonl(arg->sms_version_no);
     ((long *)buf)[2] = htonl(arg->sms_procno);
     ((long *)buf)[3] = htonl(arg->sms_argc);
 
@@ -185,7 +172,9 @@ sms_cont_recv(op, hcon, argp)
            ip = (int *) cp;
            /* we already got the overall length.. */
            for(i=1; i <4; i++) ip[i] = ntohl(ip[i]);
-           if (ip[1] != SMS_VERSION_1)
+           arg->sms_version_no = ip[1];
+           if (arg->sms_version_no != SMS_VERSION_1 &&
+               arg->sms_version_no != SMS_VERSION_2)
                arg->sms_status = SMS_VERSION_MISMATCH;
            else arg->sms_status = ip[2];
            arg->sms_argc = ip[3];
This page took 0.033235 seconds and 4 git commands to generate.