Discussion:
arplookup1(): why static sockaddr_inarp ?
(too old to reply)
David Young
2008-04-29 18:08:48 UTC
Permalink
Does anyone know why 'sin' in arplookup1() is static? If I had to guess,
it is a throwback to small-memory machines where it was desirable to
save 16 bytes on the stack.

Dave
--
David Young OJC Technologies
***@ojctech.com Urbana, IL * (217) 278-3933 ext 24

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Christos Zoulas
2008-04-29 21:37:21 UTC
Permalink
Post by David Young
Does anyone know why 'sin' in arplookup1() is static? If I had to guess,
it is a throwback to small-memory machines where it was desirable to
save 16 bytes on the stack.
No, this is bogus. Get rid of the static.

christos


--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Steven M. Bellovin
2008-04-29 22:34:40 UTC
Permalink
On Tue, 29 Apr 2008 13:08:48 -0500
Post by David Young
Does anyone know why 'sin' in arplookup1() is static? If I had to
guess, it is a throwback to small-memory machines where it was
desirable to save 16 bytes on the stack.
Does it need to be explicitly bzero'd first?


--Steve Bellovin, http://www.cs.columbia.edu/~smb

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
David Young
2008-04-29 22:35:28 UTC
Permalink
Post by Steven M. Bellovin
On Tue, 29 Apr 2008 13:08:48 -0500
Post by David Young
Does anyone know why 'sin' in arplookup1() is static? If I had to
guess, it is a throwback to small-memory machines where it was
desirable to save 16 bytes on the stack.
Does it need to be explicitly bzero'd first?
Yes.

Dave
--
David Young OJC Technologies
***@ojctech.com Urbana, IL * (217) 278-3933 ext 24

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Loading...