projects
/
l2tpns.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Apply patch from Geoffrey D. Bennett to fix retry of control packets.
[l2tpns.git]
/
l2tpns.c
diff --git
a/l2tpns.c
b/l2tpns.c
index
8e3f762
..
8fdcb53
100644
(file)
--- a/
l2tpns.c
+++ b/
l2tpns.c
@@
-4,7
+4,7
@@
// Copyright (c) 2002 FireBrick (Andrews & Arnold Ltd / Watchfront Ltd) - GPL licenced
// vim: sw=8 ts=8
// Copyright (c) 2002 FireBrick (Andrews & Arnold Ltd / Watchfront Ltd) - GPL licenced
// vim: sw=8 ts=8
-char const *cvs_id_l2tpns = "$Id: l2tpns.c,v 1.17
4 2010/01/09 13:33:41
bodea Exp $";
+char const *cvs_id_l2tpns = "$Id: l2tpns.c,v 1.17
6 2011/01/20 12:48:40
bodea Exp $";
#include <arpa/inet.h>
#include <assert.h>
#include <arpa/inet.h>
#include <assert.h>
@@
-2686,9
+2686,11
@@
void processudp(uint8_t *buf, int len, struct sockaddr_in *addr)
break;
case 2: // SCCRP
tunnel[t].state = TUNNELOPEN;
break;
case 2: // SCCRP
tunnel[t].state = TUNNELOPEN;
+ tunnel[t].lastrec = time_now;
break;
case 3: // SCCN
tunnel[t].state = TUNNELOPEN;
break;
case 3: // SCCN
tunnel[t].state = TUNNELOPEN;
+ tunnel[t].lastrec = time_now;
controlnull(t); // ack
break;
case 4: // StopCCN
controlnull(t); // ack
break;
case 4: // StopCCN
@@
-3031,7
+3033,7
@@
static void regular_cleanups(double period)
if (tunnel[t].retry <= TIME)
{
controlt *c = tunnel[t].controls;
if (tunnel[t].retry <= TIME)
{
controlt *c = tunnel[t].controls;
- uint
8
_t w = tunnel[t].window;
+ uint
16
_t w = tunnel[t].window;
tunnel[t].try++; // another try
if (tunnel[t].try > 5)
tunnelkill(t, "Timeout on control message"); // game over
tunnel[t].try++; // another try
if (tunnel[t].try > 5)
tunnelkill(t, "Timeout on control message"); // game over