Skip to content

Commit

Permalink
sync timeout parameters with the latest draft.
Browse files Browse the repository at this point in the history
  • Loading branch information
jinmei committed Jan 15, 2003
1 parent e483483 commit 1015e8b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 12 deletions.
7 changes: 3 additions & 4 deletions kame/kame/dhcp6/common.c
@@ -1,4 +1,4 @@
/* $KAME: common.c,v 1.69 2003/01/05 17:12:12 jinmei Exp $ */
/* $KAME: common.c,v 1.70 2003/01/15 13:47:32 jinmei Exp $ */
/*
* Copyright (C) 1998 and 1999 WIDE Project.
* All rights reserved.
Expand Down Expand Up @@ -1597,11 +1597,10 @@ dhcp6_reset_timer(ev)
/*
* The first Solicit message from the client on the interface
* MUST be delayed by a random amount of time between
* MIN_SOL_DELAY and MAX_SOL_DELAY.
* 0 and SOL_MAX_DELAY.
* [dhcpv6-28 17.1.2]
*/
ev->retrans = (random() % (MAX_SOL_DELAY - MIN_SOL_DELAY)) +
MIN_SOL_DELAY;
ev->retrans = (random() % (SOL_MAX_DELAY));
break;
default:
if (ev->state == DHCP6S_SOLICIT && ev->timeouts == 0) {
Expand Down
15 changes: 7 additions & 8 deletions kame/kame/dhcp6/dhcp6.h
@@ -1,4 +1,4 @@
/* $KAME: dhcp6.h,v 1.34 2003/01/05 17:12:13 jinmei Exp $ */
/* $KAME: dhcp6.h,v 1.35 2003/01/15 13:47:32 jinmei Exp $ */
/*
* Copyright (C) 1998 and 1999 WIDE Project.
* All rights reserved.
Expand Down Expand Up @@ -57,13 +57,12 @@
/* Protocol constants */

/* timer parameters (msec, unless explicitly commented) */
#define MIN_SOL_DELAY 1000
#define MAX_SOL_DELAY 5000
#define SOL_TIMEOUT 500
#define SOL_MAX_RT 30000
#define INF_TIMEOUT 500
#define INF_MAX_RT 30000
#define REQ_TIMEOUT 250
#define SOL_MAX_DELAY 1000
#define SOL_TIMEOUT 1000
#define SOL_MAX_RT 120000
#define INF_TIMEOUT 1000
#define INF_MAX_RT 120000
#define REQ_TIMEOUT 1000
#define REQ_MAX_RT 30000
#define REQ_MAX_RC 10 /* Max Request retry attempts */
#define REN_TIMEOUT 10000 /* 10secs */
Expand Down

0 comments on commit 1015e8b

Please sign in to comment.