fixed MessageManager.flush_queue()
make use of MessageManager in mihf.py