[binutils-gdb] vms-alpha: integer overflow

Alan Modra amodra@sourceware.org
Mon Oct 6 03:05:34 GMT 2025


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=b05d1d896058c41d49e44951a02dd74238ce2e4e

commit b05d1d896058c41d49e44951a02dd74238ce2e4e
Author: Alan Modra <amodra@gmail.com>
Date:   Mon Oct 6 13:24:31 2025 +1030

    vms-alpha: integer overflow
    
    image_offset takes values from section vma then increments when
    filling out section data.  Avoid signed integer overflow.
    
            * vms-alpha.c (struct vms_private_data_struct): Make image_offset
            unsigned.

Diff:
---
 bfd/vms-alpha.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/bfd/vms-alpha.c b/bfd/vms-alpha.c
index 36cdac68994..277cba0107e 100644
--- a/bfd/vms-alpha.c
+++ b/bfd/vms-alpha.c
@@ -304,7 +304,7 @@ struct vms_private_data_struct
 
   /* Content reading.  */
   asection *image_section;		/* section for image_ptr  */
-  file_ptr image_offset;		/* Offset for image_ptr.  */
+  ufile_ptr image_offset;		/* Offset for image_ptr.  */
 
   struct module *modules;		/* list of all compilation units */


More information about the Binutils-cvs mailing list