diff options
author | stratakis <cstratak@redhat.com> | 2018-01-23 16:11:24 +0100 |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2018-01-23 16:11:24 +0100 |
commit | e768c86ef442ef89004089a8a34ce5909ffb90f2 (patch) | |
tree | d332469497ed5a11fb27db5c7dce129544766476 /Include/Python.h | |
parent | 370d04d1dcca50a52d59f40aff4d11434f71df6b (diff) | |
download | cpython-git-e768c86ef442ef89004089a8a34ce5909ffb90f2.tar.gz |
bpo-32635: Fix a segfault when importing the crypt module with libxcrypt. (#5284)
glibc is deprecating libcrypt in favor of libxcrypt, however python assumes
that crypt.h will always be included. This change makes the header inclusion
explicit when libxcrypt is present on the system.
Diffstat (limited to 'Include/Python.h')
-rw-r--r-- | Include/Python.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Include/Python.h b/Include/Python.h index dd595ea5e4..1feb1531cc 100644 --- a/Include/Python.h +++ b/Include/Python.h @@ -35,6 +35,9 @@ #ifdef HAVE_UNISTD_H #include <unistd.h> #endif +#ifdef HAVE_CRYPT_H +#include <crypt.h> +#endif /* For size_t? */ #ifdef HAVE_STDDEF_H |