highfidelity/hifi — pull request #3246 by wangyix (2014-08-04 18:20:21+00:00)
Title: Improved SequenceNumberStats handling of out-of-sync seq nums

Fix: Simplified and improved the SequenceNumberStats code for re-syncing with a seq num sender. Now, if the seq num sender was suddenly set back by less than 1000 seq nums, those numbers would be deemed "unreasonable" rather than "duplicate", which means they'll be tracked to detect if we're out of sync with the sender.

Test: added code to randomly reset outgoing seq nums in Audio.cpp. verified that seq num tracker would re-sync and server audio echo did not stop.