We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8d4bd5e commit a6384edCopy full SHA for a6384ed
1 file changed
src/LibObjectFile/Elf/ElfSegmentRange.cs
@@ -99,17 +99,7 @@ public ulong Size
99
return 0;
100
}
101
102
- var parent = BeginSection.Parent;
103
- ulong size = 0;
104
- for (uint i = BeginSection.Index; i < EndSection.Index; i++)
105
- {
106
- var section = parent.Sections[(int)i];
107
- if (section.HasContent)
108
109
- size += section.Size;
110
- }
111
112
-
+ ulong size = EndSection.Offset - BeginSection.Offset;
113
size -= BeginOffset;
114
size += EndOffset < 0 ? (ulong)((long)EndSection.Size + EndOffset + 1) : (ulong)(EndOffset + 1);
115
return size;
0 commit comments