Exception: MachO::MagicError

Inherits:
NotAMachOError show all
Defined in:
lib/macho/exceptions.rb

Overview

Raised when a file's magic bytes are not valid Mach-O magic.

Instance Method Summary collapse

Constructor Details

#initialize(magic) ⇒ MagicError

Returns a new instance of MagicError.

Parameters:

  • num (Integer)

    the unknown number



47
48
49
# File 'lib/macho/exceptions.rb', line 47

def initialize(magic)
  super "Unrecognized Mach-O magic: 0x%02<magic>x" % { :magic => magic }
end