mirror of
https://github.com/openharmony/miscservices_time.git
synced 2026-07-19 12:02:04 -04:00
修改分支codecheck问题,回退两个makeke_shared构建对象
Signed-off-by: guduhanyan <xuyanjun27@163.com>
This commit is contained in:
@@ -17,13 +17,8 @@
|
||||
|
||||
#include <cinttypes>
|
||||
#include <mutex>
|
||||
#include <thread>
|
||||
#include <atomic>
|
||||
#include <vector>
|
||||
#include <chrono>
|
||||
#include <functional>
|
||||
#include <map>
|
||||
#include <random>
|
||||
#include "batch.h"
|
||||
#include "timer_handler.h"
|
||||
|
||||
|
||||
@@ -13,18 +13,18 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <sys/epoll.h>
|
||||
#include <iostream>
|
||||
#include <cstring>
|
||||
#include <sys/timerfd.h>
|
||||
#include <unistd.h>
|
||||
#include <linux/rtc.h>
|
||||
#include <cstring>
|
||||
#include <fcntl.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <dirent.h>
|
||||
#include <sys/epoll.h>
|
||||
#include <sys/timerfd.h>
|
||||
#include <sys/time.h>
|
||||
#include <dirent.h>
|
||||
#include <sstream>
|
||||
#include <fstream>
|
||||
#include <iostream>
|
||||
#include <linux/rtc.h>
|
||||
#include "timer_handler.h"
|
||||
|
||||
namespace OHOS {
|
||||
@@ -65,7 +65,7 @@ std::shared_ptr<TimerHandler> TimerHandler::Create()
|
||||
}
|
||||
}
|
||||
|
||||
std::shared_ptr<TimerHandler> handler = std::make_shared<TimerHandler>(fds, epollfd);
|
||||
std::shared_ptr<TimerHandler> handler = std::shared_ptr<TimerHandler>(new TimerHandler(fds, epollfd));
|
||||
for (size_t i = 0; i < fds.size(); i++) {
|
||||
epoll_event event {};
|
||||
event.events = EPOLLIN | EPOLLWAKEUP;
|
||||
|
||||
@@ -52,7 +52,7 @@ std::shared_ptr<TimerManager> TimerManager::Create()
|
||||
TIME_HILOGE(TIME_MODULE_SERVICE, "Create Timer handle failed.");
|
||||
return nullptr;
|
||||
}
|
||||
return std::make_shared<TimerManager>(impl);
|
||||
return std::shared_ptr<TimerManager>(new TimerManager(impl));
|
||||
}
|
||||
|
||||
TimerManager::TimerManager(std::shared_ptr<TimerHandler> impl)
|
||||
|
||||
Reference in New Issue
Block a user