diff --git a/macho.go b/macho.go index 2a46a1d..28ba63a 100644 --- a/macho.go +++ b/macho.go @@ -21,7 +21,6 @@ import ( "debug/gosym" "debug/macho" "fmt" - "math" "os" ) @@ -42,22 +41,8 @@ func openMachO(fp string) (*machoFile, error) { var _ fileHandler = (*machoFile)(nil) type machoFile struct { - file *macho.File - osFile *os.File - textStart uint64 -} - -func (m *machoFile) trySetTextStart() { - addr := uint64(math.MaxUint64) - if m.file.Symtab != nil { - for _, sym := range m.file.Symtab.Syms { - if sym.Name == "runtime.text" { - addr = sym.Value - break - } - } - } - m.textStart = addr + file *macho.File + osFile *os.File } func (m *machoFile) GetParsedFile() any {