Skip to content

Commit af204e4

Browse files
authored
[3.10] GH-98671: bpo-46670: Fix #ifdef in sha3module.c (GH-90828) (#98677)
1 parent db1c3d6 commit af204e4

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Fix ``NO_MISALIGNED_ACCESSES`` being not defined for the SHA3 extension
2+
when ``HAVE_ALIGNED_REQUIRED`` is set. Allowing builds on hardware that
3+
unaligned memory accesses are not allowed.

Modules/_sha3/sha3module.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
#endif
6666

6767
/* Prevent bus errors on platforms requiring aligned accesses such ARM. */
68-
#if HAVE_ALIGNED_REQUIRED && !defined(NO_MISALIGNED_ACCESSES)
68+
#if defined(HAVE_ALIGNED_REQUIRED) && !defined(NO_MISALIGNED_ACCESSES)
6969
#define NO_MISALIGNED_ACCESSES
7070
#endif
7171

0 commit comments

Comments
 (0)