Skip to content

Commit 08b34af

Browse files
gh-123917: Fix crypt check in configure
Check if the function is not NULL to use the variable. Otherwise, a compiler can remove the variable making the check useless. Co-Authored-By: Paul Smith <[email protected]>
1 parent 8ca75ee commit 08b34af

File tree

3 files changed

+4
-0
lines changed

3 files changed

+4
-0
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Fix the check for the ``crypt()`` function in the configure script. Patch by
2+
Paul Smith and Victor Stinner.

configure

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

configure.ac

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5243,6 +5243,7 @@ WITH_SAVE_ENV([
52435243
#else
52445244
void *x = crypt;
52455245
#endif
5246+
return (x != NULL);
52465247
])
52475248
], [ac_cv_crypt_crypt=yes], [ac_cv_crypt_crypt=no])
52485249
])

0 commit comments

Comments
 (0)