# Buggy code
def _fast_memory_load(self, addr):
    """
    Perform a fast memory loading of static content from static regions, a.k.a regions that are mapped to the
    memory by the loader.

    :param int addr: Address to read from.
    :return: A tuple of the data (cffi.CData) and the max size in the current continuous block, or (None, None) if
             the address does not exist.
    :rtype: tuple
    """

    try:
        buff, size = self.project.loader.memory.read_bytes_c(addr)
        return buff, size

    except KeyError:
        return None


# Traceback (TypeError)
Traceback (most recent call last):
File "/usr/lib/python2.7/multiprocessing/process.py", line 258, in _bootstrap
self.run()
File "/usr/lib/python2.7/multiprocessing/process.py", line 114, in run
self._target(*self._args, **self._kwargs)
File "gfh_gen_cfg.py", line 23, in worker
g = b.analyses.CFG(fail_fast=True)
File "/home/angr/angr-dev/angr/angr/analyses/analysis.py", line 96, in make_analysis
oself.__init__(*args, **kwargs)
File "/home/angr/angr-dev/angr/angr/analyses/cfg/cfg.py", line 58, in __init__
CFGFast.__init__(self, **kwargs)
File "/home/angr/angr-dev/angr/angr/analyses/cfg/cfg_fast.py", line 819, in __init__
self._analyze()
File "/home/angr/angr-dev/angr/angr/analyses/forward_analysis.py", line 508, in _analyze
self._analysis_core_baremetal()
File "/home/angr/angr-dev/angr/angr/analyses/forward_analysis.py", line 633, in _analysis_core_baremetal
self._process_job_and_get_successors(job_info)
File "/home/angr/angr-dev/angr/angr/analyses/forward_analysis.py", line 651, in _process_job_and_get_successors
successors = self._get_successors(job)
File "/home/angr/angr-dev/angr/angr/analyses/cfg/cfg_fast.py", line 1210, in _get_successors
jobs = self._scan_block(addr, current_function_addr, jumpkind, src_node, src_ins_addr, src_stmt_idx)
File "/home/angr/angr-dev/angr/angr/analyses/cfg/cfg_fast.py", line 1484, in _scan_block
previous_src_ins_addr, previous_src_stmt_idx)
File "/home/angr/angr-dev/angr/angr/analyses/cfg/cfg_fast.py", line 1656, in _scan_irsb
stmt_idx
File "/home/angr/angr-dev/angr/angr/analyses/cfg/cfg_fast.py", line 1695, in _create_jobs
jumpkind
File "/home/angr/angr-dev/angr/angr/analyses/cfg/cfg_fast.py", line 2354, in _resolve_indirect_jump_timelessly
r, resolved_targets = res.resolve(self, addr, func_addr, block, jumpkind)
File "/home/angr/angr-dev/angr/angr/analyses/cfg/indirect_jump_resolvers/x86_pe_iat.py", line 27, in resolve
target = cfg._fast_memory_load_pointer(slot)
File "/home/angr/angr-dev/angr/angr/analyses/cfg/cfg_base.py", line 862, in _fast_memory_load_pointer
buf, size = self._fast_memory_load(addr)
TypeError: 'NoneType' object is not iterable

# Fixed code
def _fast_memory_load(self, addr):
    """
    Perform a fast memory loading of static content from static regions, a.k.a regions that are mapped to the
    memory by the loader.

    :param int addr: Address to read from.
    :return: A tuple of the data (cffi.CData) and the max size in the current continuous block, or (None, None) if
             the address does not exist.
    :rtype: tuple
    """

    try:
        buff, size = self.project.loader.memory.read_bytes_c(addr)
        return buff, size

    except KeyError:
        return None, None