aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf.c
diff options
context:
space:
mode:
Diffstat (limited to 'bfd/elf.c')
-rw-r--r--bfd/elf.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/bfd/elf.c b/bfd/elf.c
index 966ada0..33a3a7d 100644
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -8000,7 +8000,9 @@ elfcore_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
memcpy (&psinfo, note->descdata, sizeof (psinfo));
+#if defined (HAVE_PSINFO_T_PR_PID) || defined (HAVE_PRPSINFO_T_PR_PID)
elf_tdata (abfd)->core_pid = psinfo.pr_pid;
+#endif
elf_tdata (abfd)->core_program
= _bfd_elfcore_strndup (abfd, psinfo.pr_fname,
sizeof (psinfo.pr_fname));
@@ -8017,7 +8019,9 @@ elfcore_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
memcpy (&psinfo, note->descdata, sizeof (psinfo));
+#if defined (HAVE_PSINFO32_T_PR_PID) || defined (HAVE_PRPSINFO32_T_PR_PID)
elf_tdata (abfd)->core_pid = psinfo.pr_pid;
+#endif
elf_tdata (abfd)->core_program
= _bfd_elfcore_strndup (abfd, psinfo.pr_fname,
sizeof (psinfo.pr_fname));