def nameDispatch(address): '''Name the dispatch function at the specified address in quicktime.qts''' try: start, end = function.getRange(address) except ValueError: print '%x making a function'% address function.make(address) start, end = function.getRange(address) try: ea = FindLastAssignment(address, 'eax') code = getDispatchCode(ea) except ValueError: print '%08x - Unable to find dispatch code'% address return ofs = database.getoffset(start) function.setName(start, 'dispatch_%08x_%x'% (code, ofs)) function.tag(start, 'code', hex(code)) function.tag(start, 'group', 'dispatch') try: function.tag(start, 'realname', __quicktime.qt_fv_list[code]) except KeyError: pass try: function.tag(start, 'address', hex(resolveDispatcher(code)), repeatable=True) except: pass
def nameDispatch(address): '''Name the dispatch function at the specified address in quicktime.qts''' try: start, end = function.range(address) except ValueError: print '%x making a function'% address function.make(address) start, end = function.range(address) try: ea = FindLastAssignment(address, 'eax') code = getDispatchCode(ea) except ValueError: print '%08x - Unable to find dispatch code'% address return ofs = database.getoffset(start) function.setName(start, 'dispatch_%08x_%x'% (code, ofs)) function.tag(start, 'code', hex(code)) function.tag(start, 'group', 'dispatch') try: function.tag(start, 'realname', app.__quicktime.qt_fv_list[code]) except KeyError: pass try: function.tag(start, 'address', hex(resolveDispatcher(code)), repeatable=True) except: pass
def offset(ea): min, _ = getRange(ea) return database.getoffset(min)
def offset(key=None): ea = address(key) return database.getoffset(ea)
def offset(ea): min,_ = getRange(ea) return database.getoffset(min)