[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master b331bf6d8a2 2/2: Correct build on systems without PAGE_MASK
From: |
Po Lu |
Subject: |
master b331bf6d8a2 2/2: Correct build on systems without PAGE_MASK |
Date: |
Mon, 18 Sep 2023 02:16:56 -0400 (EDT) |
branch: master
commit b331bf6d8a21ef3ac7e70d3f4a937e4256178d55
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>
Correct build on systems without PAGE_MASK
* exec/exec.c (write_load_command) <PAGE_MASK, PAGE_SIZE>:
Uniformly define even if !HAVE_GETPAGESIZE.
---
exec/exec.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/exec/exec.c b/exec/exec.c
index dae05755675..231b5b1c46a 100644
--- a/exec/exec.c
+++ b/exec/exec.c
@@ -309,10 +309,10 @@ write_load_command (program_header *header, bool
use_alternate,
#else /* HAVE_GETPAGESIZE */
if (!pagesize)
pagesize = sysconf (_SC_PAGESIZE);
+#endif /* HAVE_GETPAGESIZE */
#define PAGE_MASK (~(pagesize - 1))
#define PAGE_SIZE (pagesize)
-#endif /* HAVE_GETPAGESIZE */
#endif /* PAGE_MASK */
start = header->p_vaddr & PAGE_MASK;