20211012LTS03

Signed-off-by: guduhanyan <xuyanjun27@163.com>
This commit is contained in:
guduhanyan
2021-10-12 20:16:22 +08:00
parent 71d58dbd36
commit c8f5403fd8
2 changed files with 6 additions and 6 deletions
+5 -5
View File
@@ -31,12 +31,12 @@
#include <linux/rtc.h>
#include "pthread.h"
#include "time_service.h"
#include "time_zone_info.h"
#include "time_common.h"
#include "system_ability.h"
#include "system_ability_definition.h"
#include "iservice_registry.h"
#include "time_service.h"
namespace OHOS {
namespace MiscServices {
@@ -64,8 +64,8 @@ std::shared_ptr<MiscServices::TimeServiceNotify> TimeService::timeServiceNotify_
std::shared_ptr<TimerManager> TimeService::timerManagerHandler_ = nullptr;
TimeService::TimeService(int32_t systemAbilityId, bool runOnCreate)
: SystemAbility(systemAbilityId, runOnCreate),
state_(ServiceRunningState::STATE_NOT_START),
: SystemAbility(systemAbilityId, runOnCreate),
state_(ServiceRunningState::STATE_NOT_START),
rtc_id(get_wall_clock_rtc_id())
{
TIME_HILOGI(TIME_MODULE_SERVICE, " TimeService Start.");
@@ -240,7 +240,7 @@ uint64_t TimeService::CreateTimer(int32_t type, bool repeat, uint64_t interval,
0);
}
bool TimeService::StartTimer(uint64_t timerId, uint64_t triggerTimes)
bool TimeService::StartTimer(uint64_t timerId, uint64_t triggerTimes)
{
uint64_t triggerTimesIn = (triggerTimes < MIN_TRIGGER_TIMES) ? MIN_TRIGGER_TIMES : triggerTimes;
if (timerManagerHandler_ == nullptr) {
@@ -275,7 +275,7 @@ bool TimeService::StopTimer(uint64_t timerId)
return ret;
}
bool TimeService::DestroyTimer(uint64_t timerId)
bool TimeService::DestroyTimer(uint64_t timerId)
{
if (timerManagerHandler_ == nullptr) {
TIME_HILOGE(TIME_MODULE_SERVICE, "Timer manager nullptr.");
+1 -1
View File
@@ -390,7 +390,7 @@ bool TimerManager::TriggerTimersLocked(std::vector<std::shared_ptr<TimerInfo>> &
break;
}
alarmBatches_.erase(alarmBatches_.begin());
TIME_HILOGI(TIME_MODULE_SERVICE, "after erase alarmBatches_.size= %{public}d",
TIME_HILOGI(TIME_MODULE_SERVICE, "after erase alarmBatches_.size= %{public}d",
static_cast<int>(alarmBatches_.size()));
const auto n = batch->Size();