Summary: Currently, the tryRunAfterDelay implicitly converts a negative delay in int to unsigned int. With this change, the api makes it clear than only unsinged int is accepted as valid delay
Reviewed By: yfeldblum
Differential Revision:
D2710034
fb-gh-sync-id:
cb3c6b91bb86bbe07fa0e590b2ea871242d19745
}
void EventBase::runAfterDelay(const Cob& cob,
- int milliseconds,
+ uint32_t milliseconds,
TimeoutManager::InternalEnum in) {
if (!tryRunAfterDelay(cob, milliseconds, in)) {
folly::throwSystemError(
}
bool EventBase::tryRunAfterDelay(const Cob& cob,
- int milliseconds,
+ uint32_t milliseconds,
TimeoutManager::InternalEnum in) {
CobTimeout* timeout = new CobTimeout(this, cob, in);
if (!timeout->scheduleTimeout(milliseconds)) {
*/
void runAfterDelay(
const Cob& c,
- int milliseconds,
+ uint32_t milliseconds,
TimeoutManager::InternalEnum in = TimeoutManager::InternalEnum::NORMAL);
/**
* */
bool tryRunAfterDelay(
const Cob& cob,
- int milliseconds,
+ uint32_t milliseconds,
TimeoutManager::InternalEnum in = TimeoutManager::InternalEnum::NORMAL);
/**