- Don't use legacy function in a non-legacy one. This gives us

possibility to compile libalias without legacy support.
- Use correct way to mark variable as unused.

Approved by:	re (dwhite)
This commit is contained in:
Gleb Smirnoff 2005-06-20 08:31:48 +00:00
parent 6cc00fe24c
commit 72f2d6578c

View File

@ -71,12 +71,11 @@ purposes);
#endif
u_short
LibAliasInternetChecksum(struct libalias *la, u_short * ptr, int nbytes)
LibAliasInternetChecksum(struct libalias *la __unused, u_short * ptr,
int nbytes)
{
int sum, oddbyte;
(void)la;
sum = 0;
while (nbytes > 1) {
sum += *ptr++;
@ -96,7 +95,7 @@ LibAliasInternetChecksum(struct libalias *la, u_short * ptr, int nbytes)
u_short
IpChecksum(struct ip *pip)
{
return (PacketAliasInternetChecksum((u_short *) pip,
return (LibAliasInternetChecksum(NULL, (u_short *) pip,
(pip->ip_hl << 2)));
}