MCPcopy Create free account
hub / github.com/async-profiler/async-profiler / validHeader

Method validHeader

src/symbols_linux.cpp:230–235  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

228 }
229
230 bool validHeader() {
231 unsigned char* ident = _header->e_ident;
232 return ident[0] == 0x7f && ident[1] == 'E' && ident[2] == 'L' && ident[3] == 'F'
233 && ident[4] == ELFCLASS_SUPPORTED && ident[5] == ELFDATA2LSB && ident[6] == EV_CURRENT
234 && _header->e_shstrndx != SHN_UNDEF;
235 }
236
237 ElfSection* section(int index) {
238 return (ElfSection*)(_sections + index * _header->e_shentsize);

Callers 2

parseFileMethod · 0.80
parseProgramHeadersMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected