summaryrefslogtreecommitdiff
path: root/libdwfl/libdwfl.h
diff options
context:
space:
mode:
authorJan Kratochvil <jan.kratochvil@redhat.com>2014-02-22 21:06:49 +0100
committerJan Kratochvil <jan.kratochvil@redhat.com>2014-02-22 22:05:04 +0100
commit25a2c8477e8bc165a7c78719e7f0f30514abfc57 (patch)
tree620ec2a62487b104792212527395ed552f29d2e9 /libdwfl/libdwfl.h
parent112bcc0bebc8c3499acc67d04f292b3908e4fbcc (diff)
downloadelfutils-jankratochvil/devmem.tar.gz
Access deleted files by /dev/PID/mem.jankratochvil/devmem
libdwfl/ 2014-02-22 Jan Kratochvil <jan.kratochvil@redhat.com> Access deleted files by /dev/PID/mem. * dwfl_module.c (dwfl_report_module_pid): New function. * dwfl_module_getdwarf.c (open_elf): Call __libdw_open_file_at_offset. * libdwfl.h (dwfl_report_module_pid): New declaration. * libdwflP.h (struct Dwfl_Module): New field pid. (INTDECL (dwfl_report_module_pid)): New. * linux-proc-maps.c (proc_maps_report): New variable first_high. (proc_maps_report) (report): Possibly call dwfl_report_module_pid. tests/ 2014-02-22 Jan Kratochvil <jan.kratochvil@redhat.com> Access deleted files by /dev/PID/mem. * Makefile.am (check_PROGRAMS): Add deleted and deleted-lib.so. (TESTS, EXTRA_DIST): Add run-deleted.sh. (deleted_LDADD, deleted_lib_so_LDFLAGS, deleted_lib_so_CFLAGS): New. * deleted-lib.c: New file. * deleted.c: New file. * run-deleted.sh: New file. Signed-off-by: Jan Kratochvil <jan.kratochvil@redhat.com>
Diffstat (limited to 'libdwfl/libdwfl.h')
-rw-r--r--libdwfl/libdwfl.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/libdwfl/libdwfl.h b/libdwfl/libdwfl.h
index 2bb4f455..cedadaef 100644
--- a/libdwfl/libdwfl.h
+++ b/libdwfl/libdwfl.h
@@ -145,6 +145,12 @@ extern int dwfl_report_segment (Dwfl *dwfl, int ndx,
extern Dwfl_Module *dwfl_report_module (Dwfl *dwfl, const char *name,
Dwarf_Addr start, Dwarf_Addr end);
+/* Call dwfl_report_module with support of possibly deleted files of running
+ live process with pid PID. */
+extern Dwfl_Module *dwfl_report_module_pid (Dwfl *dwfl, const char *name,
+ Dwarf_Addr start, Dwarf_Addr end,
+ pid_t pid);
+
/* Report a module to address BASE with start and end addresses computed
from the ELF program headers in the given file - see the table below.
FD may be -1 to open FILE_NAME. On success, FD is consumed by the