Commit 4f8c4177 authored by Dan Melnic's avatar Dan Melnic Committed by Facebook Github Bot

Round up microseconds to nearest millisecond value in the default...

Round up microseconds to nearest millisecond value in the default TimeoutManager::scheduleTimeoutHighRes implementation

Summary:
Round up microseconds to nearest millisecond value in the default TimeoutManager::scheduleTimeoutHighRes implementation

(Note: this ignores all push blocking failures!)

Reviewed By: yfeldblum

Differential Revision: D14702027

fbshipit-source-id: b0c710c25c1d9b92ebf28e490507eb3dc3f4db31
parent 1cb399a3
...@@ -74,7 +74,7 @@ TimeoutManager::TimeoutManager() ...@@ -74,7 +74,7 @@ TimeoutManager::TimeoutManager()
bool TimeoutManager::scheduleTimeoutHighRes( bool TimeoutManager::scheduleTimeoutHighRes(
AsyncTimeout* obj, AsyncTimeout* obj,
timeout_type_high_res timeout) { timeout_type_high_res timeout) {
timeout_type timeout_ms = folly::chrono::round<timeout_type>(timeout); timeout_type timeout_ms = folly::chrono::ceil<timeout_type>(timeout);
return scheduleTimeout(obj, timeout_ms); return scheduleTimeout(obj, timeout_ms);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment