fix monitor mem bug