-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 10/03/10 11:49, David Sommerseth wrote: > From: David Sommerseth <d...@users.sourceforge.net> > > This is to include peercred support on hosts where _GNU_SOURCE is not > defined by default. This issue has been found on Gentoo with glibc-2.8. > > The solution was discussed on the IRC meeting March 4, 2010 > in #openvpn-discussions. > <http://thread.gmane.org/gmane.network.openvpn.devel/3242> > > Signed-off-by: David Sommerseth <d...@users.sourceforge.net> > --- > syshead.h | 4 ++++ > 1 files changed, 4 insertions(+), 0 deletions(-) >
This is the "Gentoo patch", modified to be more generic. In the IRC meeting I said I would try to make this change only in socket.c, but that was not possible. TARGET_LINUX is defined in config.h, and not available before syshead.h is included, as that is a wrapper which either includes config.h or config-win32.h, depending on OS. Further defining _GNU_SOURCE after including syshead.h would not make any difference at all, as it needs to be defined before sys/socket.h is loaded. Therefore, I'd prefer a second review on this patch. kind regards, David Sommerseth -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/ iEYEARECAAYFAkuXjQsACgkQDC186MBRfrorFQCePuxnsCBq3pIcPJ3mG1zZO2Y9 4FAAniyfy82e0vJhep0TUvQeI+7nzZsr =bTNV -----END PGP SIGNATURE-----