Subject: Re: rarpd stops listening
To: =?iso-8859-1?Q?P=E5llen?= <pollen@astrakan.hig.se>
From: David Brownlee <abs@netbsd.org>
List: port-i386
Date: 02/10/2000 19:13:00
This message is in MIME format. The first part should be readable text,
while the remaining parts are likely unreadable without MIME-aware tools.
Send mail to mime@docserver.cac.washington.edu for more info.
--0-98428806-950209980=:22416
Content-Type: TEXT/PLAIN; charset=X-UNKNOWN
Content-Transfer-Encoding: QUOTED-PRINTABLE
=09Switching this to tech-net.
=09The story so far: rarpd stops answering requests. Its present
=09in 1.3, 1.4 and -current, and P=E5llen is testing a rarpd with
=09extra debug.
=09I expected it to die - I'd just added extra debug to try to
=09help determine where.
=09Interestingly this appears to read a second packet, get into
=09rarp_check() but never exit that loop. I'm pretty certain it
=09should be getting into rarp_process(), and maybe rarp_reply().
=09Apologies for this tortuous process - another rarpd with updated
=09debugging attached.
=09Hopefully with this one we should be able to work out where its
=09going awry...
=09=09David/absolute
On Thu, 10 Feb 2000, [iso-8859-1] P=E5llen wrote:
> Even this one dies...
>=20
> DBG exit select
> DBG data received on ne0
> DBG read 60
> got a packet
--0-98428806-950209980=:22416
Content-Type: TEXT/PLAIN; charset=US-ASCII; name="rarpd.c"
Content-Transfer-Encoding: BASE64
Content-ID: <Pine.NEB.4.21.0002101913000.22416@oblivion.mono.org>
Content-Description:
Content-Disposition: attachment; filename="rarpd.c"
LyoJJE5ldEJTRDogcmFycGQuYyx2IDEuMzUgMjAwMC8wMi8wNyAwMToxNTo1
MiBuYXRoYW53IEV4cCAkCSovDQoNCi8qDQogKiBDb3B5cmlnaHQgKGMpIDE5
OTAgVGhlIFJlZ2VudHMgb2YgdGhlIFVuaXZlcnNpdHkgb2YgQ2FsaWZvcm5p
YS4NCiAqIEFsbCByaWdodHMgcmVzZXJ2ZWQuDQogKg0KICogUmVkaXN0cmli
dXRpb24gYW5kIHVzZSBpbiBzb3VyY2UgYW5kIGJpbmFyeSBmb3Jtcywgd2l0
aCBvciB3aXRob3V0DQogKiBt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