gcc is too clueless on some platforms to tell that
(number divisible by 2 * 1.5) is an int, and thus fails spectacularly at either link or compile time. replace exprs with their int values.
This commit is contained in:
parent
0dda664f42
commit
36f6a11c63
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ip_nat.c,v 1.25 2007/05/01 19:08:05 martti Exp $ */
|
||||
/* $NetBSD: ip_nat.c,v 1.26 2007/05/02 02:59:54 dogcow Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995-2003 by Darren Reed.
|
||||
|
@ -5245,13 +5245,13 @@ int which;
|
|||
goto nat_force_flush_skipped;
|
||||
nat_last_force_flush = fr_ticks;
|
||||
|
||||
if (fr_ticks > IPF_TTLVAL(43200 * 1.5)) {
|
||||
if (fr_ticks > IPF_TTLVAL(64800)) {
|
||||
istart = IPF_TTLVAL(86400 * 4);
|
||||
interval = IPF_TTLVAL(43200);
|
||||
} else if (fr_ticks > IPF_TTLVAL(1800 * 1.5)) {
|
||||
} else if (fr_ticks > IPF_TTLVAL(2700)) {
|
||||
istart = IPF_TTLVAL(43200);
|
||||
interval = IPF_TTLVAL(1800);
|
||||
} else if (fr_ticks > IPF_TTLVAL(30 * 1.5)) {
|
||||
} else if (fr_ticks > IPF_TTLVAL(45)) {
|
||||
istart = IPF_TTLVAL(1800);
|
||||
interval = IPF_TTLVAL(30);
|
||||
} else {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ip_state.c,v 1.21 2007/05/01 19:08:05 martti Exp $ */
|
||||
/* $NetBSD: ip_state.c,v 1.22 2007/05/02 02:59:54 dogcow Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995-2003 by Darren Reed.
|
||||
|
@ -114,7 +114,7 @@ struct file;
|
|||
#if !defined(lint)
|
||||
#if defined(__NetBSD__)
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: ip_state.c,v 1.21 2007/05/01 19:08:05 martti Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: ip_state.c,v 1.22 2007/05/02 02:59:54 dogcow Exp $");
|
||||
#else
|
||||
static const char sccsid[] = "@(#)ip_state.c 1.8 6/5/96 (C) 1993-2000 Darren Reed";
|
||||
static const char rcsid[] = "@(#)Id: ip_state.c,v 2.186.2.61 2007/04/29 06:43:46 darrenr Exp";
|
||||
|
@ -3135,13 +3135,13 @@ int which, proto;
|
|||
goto force_flush_skipped;
|
||||
ips_last_force_flush = fr_ticks;
|
||||
|
||||
if (fr_ticks > IPF_TTLVAL(43200 * 1.5)) {
|
||||
if (fr_ticks > IPF_TTLVAL(64800)) {
|
||||
istart = IPF_TTLVAL(86400 * 4);
|
||||
interval = IPF_TTLVAL(43200);
|
||||
} else if (fr_ticks > IPF_TTLVAL(1800 * 1.5)) {
|
||||
} else if (fr_ticks > IPF_TTLVAL(2700)) {
|
||||
istart = IPF_TTLVAL(43200);
|
||||
interval = IPF_TTLVAL(1800);
|
||||
} else if (fr_ticks > IPF_TTLVAL(30 * 1.5)) {
|
||||
} else if (fr_ticks > IPF_TTLVAL(45)) {
|
||||
istart = IPF_TTLVAL(1800);
|
||||
interval = IPF_TTLVAL(30);
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue