def by_selector(selector): '''Return the segment associated with `selector`.''' seg = idaapi.get_segm_by_sel(selector) if seg is None: raise E.SegmentNotFoundError( u"{:s}.by_selector({:#x}) : Unable to locate the segment with the specified selector." .format(__name__, selector)) return seg
def bySelector(selector): '''Return the segment_t associated with /selector/''' s = idaapi.get_segm_by_sel(selector) if s is None: raise Exception, "segment.bySelector(%x):unable to locate segment" % selector return s
def by_selector(selector): '''Return the segment associated with `selector`.''' seg = idaapi.get_segm_by_sel(selector) if seg is None: raise E.SegmentNotFoundError(u"{:s}.by_selector({:#x}) : Unable to locate the segment with the specified selector.".format(__name__, selector)) return seg
def bySelector(selector): '''Return the segment_t associated with /selector/''' s = idaapi.get_segm_by_sel(selector) if s is None: raise Exception, "segment.bySelector(%x):unable to locate segment"% selector return s
def by_selector(selector): '''Return the segment associated with ``selector``.''' s = idaapi.get_segm_by_sel(selector) if s is None: raise LookupError("{:s}.by_selector({:x}) : Unable to locate segment".format(__name__, selector)) return s