macho: Improve macho_calculate_sizes

pvs-studio error 'V629 Consider inspecting the '1 << s->align' expression.
Bit shifting of the 32-bit value with a subsequent expansion to the 64-bit type.'

Signed-off-by: Martin Lindhe <martin-commit@ubique.se>
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
This commit is contained in:
Martin Lindhe 2016-11-16 16:32:19 +01:00 committed by Cyrill Gorcunov
parent d551b431a1
commit ec8b2081d3

View File

@ -1109,7 +1109,7 @@ static void macho_calculate_sizes (void)
if (s->align == -1)
s->align = DEFAULT_SECTION_ALIGNMENT;
newaddr = ALIGN(s->addr, 1 << s->align);
newaddr = ALIGN(s->addr, 1L << s->align);
s->addr = newaddr;
seg_vmsize = newaddr + s->size;