Grab ADJUST_CHECKSUM() macro from alias_local.h.

This commit is contained in:
Ruslan Ermilov 2000-08-31 12:54:55 +00:00
parent 305d10699e
commit 0ac308534e
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=65281
2 changed files with 0 additions and 34 deletions

View File

@ -44,23 +44,6 @@
#include "alias_local.h"
#define ADJUST_CHECKSUM(acc, cksum) { \
acc += cksum; \
if (acc < 0) \
{ \
acc = -acc; \
acc = (acc >> 16) + (acc & 0xffff); \
acc += acc >> 16; \
cksum = (u_short) ~acc; \
} \
else \
{ \
acc = (acc >> 16) + (acc & 0xffff); \
acc += acc >> 16; \
cksum = (u_short) acc; \
} \
}
typedef struct {
struct in_addr oldaddr;
u_short oldport;

View File

@ -44,23 +44,6 @@
#include "alias_local.h"
#define ADJUST_CHECKSUM(acc, cksum) { \
acc += cksum; \
if (acc < 0) \
{ \
acc = -acc; \
acc = (acc >> 16) + (acc & 0xffff); \
acc += acc >> 16; \
cksum = (u_short) ~acc; \
} \
else \
{ \
acc = (acc >> 16) + (acc & 0xffff); \
acc += acc >> 16; \
cksum = (u_short) acc; \
} \
}
typedef struct {
struct in_addr oldaddr;
u_short oldport;