fixed bug when receiving the same message twice within a very short time interval (issue #230)