<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def __get_instructions(self):
        "Get info from sockets"
        if self.mode == 'c':
            c, m = utils.recv(self.__s)
            inst = [(c, m, self.__s)]
        else:
            inst = []
            with self.__client_list_lock:
                for com in self.clients:
                    c, m = utils.recv(com)
                    if c is not None:
                        inst.append((c, m, com))
        return inst