* bfd-in.h (bfd_get_section_limit): Define.
[deliverable/binutils-gdb.git] / bfd / bfd-in2.h
index 65a4a10213ec15f42c8258c3d3fdf67a86f44e04..a3ace1138ad618d0c77026d62d6c27311cd43c6d 100644 (file)
@@ -328,6 +328,10 @@ typedef struct bfd_section *sec_ptr;
 #define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (ptr)->lma = (val)), ((ptr)->user_set_vma = TRUE), TRUE)
 #define bfd_set_section_alignment(bfd, ptr, val) (((ptr)->alignment_power = (val)),TRUE)
 #define bfd_set_section_userdata(bfd, ptr, val) (((ptr)->userdata = (val)),TRUE)
+/* Find the address one past the end of SEC.  */
+#define bfd_get_section_limit(bfd, sec) \
+  (((sec)->rawsize ? (sec)->rawsize : (sec)->size) \
+   / bfd_octets_per_byte (bfd))
 
 typedef struct stat stat_type;
 \f
This page took 0.023869 seconds and 4 git commands to generate.