Mercurial > hg > nginx
comparison auto/configure @ 8128:79c04253bc43
Win32: i386 now assumed when crossbuilding (ticket #2416).
Previously, NGX_MACHINE was not set when crossbuilding, resulting in
NGX_ALIGNMENT=16 being used in 32-bit builds (if not explicitly set to a
correct value). This in turn might result in memory corruption in
ngx_palloc() (as there are no usable aligned allocator on Windows, and
normal malloc() is used instead, which provides 8 byte alignment on
32-bit platforms).
To fix this, now i386 machine is set when crossbuilding, so nginx won't
assume strict alignment requirements.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Thu, 23 Feb 2023 18:15:59 +0300 |
parents | f18db38a9826 |
children |
comparison
equal
deleted
inserted
replaced
8127:17b3efb45b17 | 8128:79c04253bc43 |
---|---|
42 esac | 42 esac |
43 | 43 |
44 else | 44 else |
45 echo "building for $NGX_PLATFORM" | 45 echo "building for $NGX_PLATFORM" |
46 NGX_SYSTEM=$NGX_PLATFORM | 46 NGX_SYSTEM=$NGX_PLATFORM |
47 NGX_MACHINE=i386 | |
47 fi | 48 fi |
48 | 49 |
49 . auto/cc/conf | 50 . auto/cc/conf |
50 | 51 |
51 if [ "$NGX_PLATFORM" != win32 ]; then | 52 if [ "$NGX_PLATFORM" != win32 ]; then |