summaryrefslogtreecommitdiffstats
path: root/libdwfl/linux-proc-maps.c
diff options
context:
space:
mode:
Diffstat (limited to 'libdwfl/linux-proc-maps.c')
-rw-r--r--libdwfl/linux-proc-maps.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/libdwfl/linux-proc-maps.c b/libdwfl/linux-proc-maps.c
index 4ae1e74a..c4438c0f 100644
--- a/libdwfl/linux-proc-maps.c
+++ b/libdwfl/linux-proc-maps.c
@@ -26,6 +26,10 @@
the GNU Lesser General Public License along with this program. If
not, see <http://www.gnu.org/licenses/>. */
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
#include "libdwflP.h"
#include <inttypes.h>
#include <sys/types.h>
@@ -418,7 +422,7 @@ dwfl_linux_proc_find_elf (Dwfl_Module *mod __attribute__ ((unused)),
if (fd < 0)
goto detach;
- *elfp = elf_from_remote_memory (base, getpagesize (), NULL,
+ *elfp = elf_from_remote_memory (base, sysconf (_SC_PAGESIZE), NULL,
&read_proc_memory, &fd);
close (fd);