'Test whether a Corefile matches our process
Speculatively load a Corefile without informing the user, so that we
can check if it matches the process we\'re looking for.
Arguments:
path(str): Path to the corefile on disk
Returns:
`bool`: ``True`` if the Corefile matches, ``False`` otherwise.'

def load_core_check_pid(self):

    try:
        with context.quiet:
            with tempfile.NamedTemporaryFile() as tmp:
                tmp.write(self.read(self.core_path))
                tmp.flush()
                return Corefile(tmp.name).pid
    except Exception:
        pass
    return (-1)
