On Tue, 2018-02-20 at 23:48 +0100, Matthias Gerstner wrote: > Hello! > > I hope I have found the right place to report this. > > I have recently upgraded from nfs-utils-1.3.4 to nfs-utils-2.3.1 on a Gentoo > Linux (hardened) system. After this upgrade the rpc.svcgssd crashes on my > kerberized NFS server each time a client tries to mount an NFS export. <snip> > > I debugged this a bit and strange things came about. There seem to be > duplicate instances of the local_realms variable in the > support/nfsidmap/nfsidmap_common.c compilation unit: <snip> > So there's one instance of the variable that was actually assigned the > expected data. And there's another one that is at NULL and returned from > get_local_realms(). > > This is related to the "#pragma GCC visibility push(hidden)" in the > compilation unit. Moving it after the local_realms variable declaration fixes > the issue. I've attached a patch that does just this. > > I am not quite sure whether this is a compiler issue or an invalid use of the > visibility hidden pragma. The compiler used is: This is part of my previous work to fold libnfsidmap into the nfs-utils tree, in this case the #pragma is used to make the local_realms global accessible only by other parts of the library that need it, external users such as the nss plugin get access to it via the get_local_realms() function. I will run some tests to see if this is isolated to certain compiler versions, or if the pragma isnt working as I expected. However simply moving the #pragma hidden will change the ABI which is a problem for some, so if necessary I will instead reorganise the code to achieve the same functionality without using the pragma -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html