Re: [PATCH 1/1] Return EINVAL if the user provides a return data structure for getsockname that is too small to hold the PF_ address. This introduces a new error code but this should be OK as the error is real and would otherwise corrupt the user-application's stack, i.e., it results in trouble no matter what. I do not do a partial copy of the sockaddr structure because it does not make very much sense to retrieve only part of the socket address (e.g., ip + af_family).
From: Herbert Xu <herbert@gondor.apana.org.au>
Date: 2009-01-30 06:20:14