pwrap: Set up a pthread_atfork() handler to not delete or config directory
authorAndreas Schneider <asn@samba.org>
Fri, 20 Mar 2020 11:06:58 +0000 (12:06 +0100)
committerAndreas Schneider <asn@samba.org>
Fri, 20 Mar 2020 12:08:34 +0000 (13:08 +0100)
commit70f44f4b1f46ae51e63dc7607a67e74f35f7d756
tree53a2d5ceeb5cf52a558c052dab9b20d75a50a58a
parent84e0bd0530c3197d1aba37beb918f3815fa891ca
pwrap: Set up a pthread_atfork() handler to not delete or config directory

Python3 has some strange behavior. It forks a child which then exits.
This child calls the destructor which deletes our /tmp/pam.X directory.

As we later try to bind the symbol the directory is gone and we detected
and error which results in exit(-1).

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
src/pam_wrapper.c