Allow smaller pts decrease.

GitOrigin-RevId: 31e2429ec98b9d64eb5d38b07a9a356b038cf94f
This commit is contained in:
levlam 2018-06-23 02:19:22 +03:00
parent f18dea245c
commit 97e6e99eaf
1 changed files with 2 additions and 2 deletions

View File

@ -289,8 +289,8 @@ Promise<> UpdatesManager::set_pts(int32 pts, const char *source) {
return result;
}
Promise<> result;
if (pts > get_pts() || (0 < pts && pts < get_pts() - 999999)) { // pts can only go up or drop cardinally
if (pts < get_pts() - 999999) {
if (pts > get_pts() || (0 < pts && pts < get_pts() - 399999)) { // pts can only go up or drop cardinally
if (pts < get_pts() - 399999) {
LOG(WARNING) << "Pts decreases from " << get_pts() << " to " << pts << " from " << source << ". " << get_state();
} else {
LOG(INFO) << "Update pts from " << get_pts() << " to " << pts << " from " << source;