* dwarf2read.c: Don't include zlib.h or sys/mman.h.
[deliverable/binutils-gdb.git] / gdb / gdb_bfd.h
index 78d303b3a67118d3cb81c80e077cd22e2fd010e6..1dd82c319de161d8bdb5c30d2944ebf3c8aa9332 100644 (file)
@@ -1,6 +1,6 @@
 /* Definitions for BFD wrappers used by GDB.
 
-   Copyright (C) 2011
+   Copyright (C) 2011, 2012
    Free Software Foundation, Inc.
 
    This file is part of GDB.
@@ -46,4 +46,16 @@ struct bfd *gdb_bfd_ref (struct bfd *abfd);
 
 void gdb_bfd_unref (struct bfd *abfd);
 
+/* Try to read or map the contents of the section SECT.  If
+   successful, the section data is returned and *SIZE is set to the
+   size of the section data; this may not be the same as the size
+   according to bfd_get_section_size if the section was compressed.
+   The returned section data is associated with the BFD and will be
+   destroyed when the BFD is destroyed.  There is no other way to free
+   it; for temporary uses of section data, see
+   bfd_malloc_and_get_section.  SECT may not have relocations.  This
+   function will throw on error.  */
+
+const gdb_byte *gdb_bfd_map_section (asection *section, bfd_size_type *size);
+
 #endif /* GDB_BFD_H */
This page took 0.039514 seconds and 4 git commands to generate.