Fixed bug, make_max_pmi_ip() may return wrong value