[6bone] doubt about protocol independent Ping.

Pim van Pelt pim@ipng.nl
Mon, 15 Dec 2003 10:11:06 +0100


Hi,

| 		struct sockaddr_storage ss;
| 		socklen_t slen;
| 
| 		slen = sizeof(ss);
| 		error = getpeername(s, (struct sockaddr *)&ss, &slen);
Understood. I would have used 'the largest known sockaddr', which in my
case is sockaddr_un. Lookint at sockaddr_storage a bit, I think it
resembles what most people already were using in the form of a union of
sockaddr_* structs.

I see your point and understand the benefit. Thanks for the quick
pointer!

groet,
Pim

-- 
---------- - -    - - -+- - -    - - ----------
Pim van Pelt                 Email: pim@ipng.nl
http://www.ipng.nl/             IPv6 Deployment
-----------------------------------------------