MCPcopy Create free account
hub / github.com/CloverHackyColor/CloverBootloader / GetShdrByIndex

Function GetShdrByIndex

BaseTools/Source/C/GenFw/Elf32Convert.c:186–198  ·  view source on GitHub ↗

Header by Index functions

Source from the content-addressed store, hash-verified

184// Header by Index functions
185//
186STATIC
187Elf_Shdr*
188GetShdrByIndex (
189 UINT32 Num
190 )
191{
192 if (Num >= mEhdr->e_shnum) {
193 Error (NULL, 0, 3000, "Invalid", "GetShdrByIndex: Index %u is too high.", Num);
194 exit(EXIT_FAILURE);
195 }
196
197 return (Elf_Shdr*)((UINT8*)mShdrBase + Num * mEhdr->e_shentsize);
198}
199
200STATIC
201Elf_Phdr*

Callers 6

IsHiiRsrcShdrFunction · 0.70
IsStrtabShdrFunction · 0.70
FindStrtabShdrFunction · 0.70
ScanSections32Function · 0.70
WriteSections32Function · 0.70
WriteRelocations32Function · 0.70

Calls 2

exitFunction · 0.85
ErrorFunction · 0.50

Tested by

no test coverage detected