Loading media/libstagefright/foundation/ALooper.cpp +6 −1 Original line number Diff line number Diff line Loading @@ -170,7 +170,9 @@ void ALooper::post(const sp<AMessage> &msg, int64_t delayUs) { int64_t whenUs; if (delayUs > 0) { whenUs = GetNowUs() + delayUs; int64_t nowUs = GetNowUs(); whenUs = (delayUs > INT64_MAX - nowUs ? INT64_MAX : nowUs + delayUs); } else { whenUs = GetNowUs(); } Loading Loading @@ -208,6 +210,9 @@ bool ALooper::loop() { if (whenUs > nowUs) { int64_t delayUs = whenUs - nowUs; if (delayUs > INT64_MAX / 1000) { delayUs = INT64_MAX / 1000; } mQueueChangedCondition.waitRelative(mLock, delayUs * 1000ll); return true; Loading Loading
media/libstagefright/foundation/ALooper.cpp +6 −1 Original line number Diff line number Diff line Loading @@ -170,7 +170,9 @@ void ALooper::post(const sp<AMessage> &msg, int64_t delayUs) { int64_t whenUs; if (delayUs > 0) { whenUs = GetNowUs() + delayUs; int64_t nowUs = GetNowUs(); whenUs = (delayUs > INT64_MAX - nowUs ? INT64_MAX : nowUs + delayUs); } else { whenUs = GetNowUs(); } Loading Loading @@ -208,6 +210,9 @@ bool ALooper::loop() { if (whenUs > nowUs) { int64_t delayUs = whenUs - nowUs; if (delayUs > INT64_MAX / 1000) { delayUs = INT64_MAX / 1000; } mQueueChangedCondition.waitRelative(mLock, delayUs * 1000ll); return true; Loading