@staticmethod
def process_unix(path, family, inodes, filter_pid=None):
    """Parse /proc/net/unix files.

        :param path: path of the file to process
        :param family: one of socket.AF_INET, socket.AF_INET6, socket.AF_UNIX
        :param inodes: the dictionary output from ``self.get_*_inodes()``
        :param filter_pid: Optional. Only return sockets owned by this process
        """
    file = open(path, 'r')
    file.readline()
    for line in file:
        tokens = line.split()
        _, _, _, _, type_, _, inode = tokens[0:7]
        if inode in inodes:
            pairs = inodes[inode]
        else:
            pairs = [(None, -1)]
        for pid, fd in pairs:
            if filter_pid is not None and filter_pid != pid:
                continue
            else:
                if len(tokens) == 8:
                    path = tokens[-1]
                else:
                    path = ''
                type_ = int(type_)
                raddr = None
                status = 'NONE'
                yield fd, family, type_, path, raddr, status, pid
    file.close()
