forked from Imagelibrary/binutils-gdb
gas standardise md_section_align
The point here is that when valueT is 64 bits and int is 32 bits, 1 << align doesn't work for shifts larger than the size of int. (Not that anyone is likely to use such large alignments in real code.)
This commit is contained in:
@@ -380,7 +380,7 @@ valueT
|
||||
md_section_align (segT segment, valueT size)
|
||||
{
|
||||
int align = bfd_section_alignment (segment);
|
||||
return ((size + (1 << align) - 1) & -(1 << align));
|
||||
return (size + ((valueT) 1 << align) - 1) & -((valueT) 1 << align);
|
||||
}
|
||||
|
||||
symbolS *
|
||||
|
||||
Reference in New Issue
Block a user