BSD 4_3_Tahoe release
[unix-history] / usr / src / sys / netns / ns_input.c
index e23846e..15e3240 100644 (file)
@@ -1,9 +1,20 @@
 /*
 /*
- * Copyright (c) 1984, 1985, 1986 Regents of the University of California.
- * All rights reserved.  The Berkeley software License Agreement
- * specifies the terms and conditions for redistribution.
+ * Copyright (c) 1984, 1985, 1986, 1987 Regents of the University of California.
+ * All rights reserved.
  *
  *
- *     @(#)ns_input.c  7.1 (Berkeley) %G%
+ * Redistribution and use in source and binary forms are permitted
+ * provided that the above copyright notice and this paragraph are
+ * duplicated in all such forms and that any documentation,
+ * advertising materials, and other materials related to such
+ * distribution and use acknowledge that the software was developed
+ * by the University of California, Berkeley.  The name of the
+ * University may not be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
+ * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+ *
+ *     @(#)ns_input.c  7.4 (Berkeley) 6/29/88
  */
 
 #include "param.h"
  */
 
 #include "param.h"
@@ -357,7 +368,7 @@ idp_forward(idp)
                register int shift;
                x.l = 0; x.c[0] = agedelta;
                shift = (((((int)ntohs(idp->idp_len))+1)>>1)-2) & 0xf;
                register int shift;
                x.l = 0; x.c[0] = agedelta;
                shift = (((((int)ntohs(idp->idp_len))+1)>>1)-2) & 0xf;
-               x.l = idp->idp_sum + (x.l << shift);
+               x.l = idp->idp_sum + (x.s[0] << shift);
                x.l = x.s[0] + x.s[1];
                x.l = x.s[0] + x.s[1];
                if (x.l==0xffff) idp->idp_sum = 0; else idp->idp_sum = x.l;
                x.l = x.s[0] + x.s[1];
                x.l = x.s[0] + x.s[1];
                if (x.l==0xffff) idp->idp_sum = 0; else idp->idp_sum = x.l;