From 753958f7baef67762150954a68879eb9c5b75d6b Mon Sep 17 00:00:00 2001 From: David du Colombier <0intro@gmail.com> Date: Wed, 31 Mar 1999 00:00:00 +0000 Subject: [PATCH] Plan 9 from Bell Labs 1999-03-31 --- carrera/mem.h | 2 +- ip/il.c | 2 ++ port/auth.c | 6 +++++- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/carrera/mem.h b/carrera/mem.h index edf97580798d63cd7236fa6ad95e335ef97252e3..70a972c7537395328b0b17f0b8f5cc7467f20726 100644 --- a/carrera/mem.h +++ b/carrera/mem.h @@ -22,7 +22,7 @@ /* * Time */ -#define HZ 250 /* clock frequency */ +#define HZ 500 /* clock frequency */ #define MS2HZ (1000/HZ) /* millisec per clock tick */ #define TK2SEC(t) ((t)/HZ) /* ticks to seconds */ #define TK2MS(t) ((t)*MS2HZ) /* ticks to milliseconds */ diff --git a/ip/il.c b/ip/il.c index 2a7a459ecf946b831f17fa0c2a554c103a0e81d5..93db3e1fb25ceb99b05c002b3c29cce3349c721f 100644 --- a/ip/il.c +++ b/ip/il.c @@ -1055,6 +1055,7 @@ loop: ilbackoff(ic); } break; + case Ilsyncee: case Ilsyncer: if(ic->timeout <= msec) { @@ -1066,6 +1067,7 @@ loop: ilbackoff(ic); } break; + case Ilestablished: if(ic->recvd != ic->acksent && ic->acktime <= msec) ilsendctl(p, nil, Ilack, ic->next, ic->recvd, 0); diff --git a/port/auth.c b/port/auth.c index 51b33cd8634076b7a2c0769fa8d18664528007f6..4e52fe659b29d3cdf711732c4a3db92c9514c233 100644 --- a/port/auth.c +++ b/port/auth.c @@ -215,10 +215,13 @@ sysfauth(ulong *arg) validaddr(arg[1], 2*TICKETLEN, 0); c = fdtochan(arg[0], OWRITE, 0, 1); s = c->session; - if(s == 0) + if(s == 0){ + cclose(c); error("fauth must follow fsession"); + } cp = newcrypt(); if(waserror()){ + cclose(c); freecrypt(cp); nexterror(); } @@ -249,6 +252,7 @@ sysfauth(ulong *arg) cp->next = s->cache; s->cache = cp; unlock(s); + cclose(c); poperror(); return 0; }