From 35a2212dab007221bada21811fac512fd636fdbd Mon Sep 17 00:00:00 2001 From: lyj_love_code Date: Sun, 26 Sep 2021 20:50:57 +0800 Subject: [PATCH] fix codex Signed-off-by: lyj_love_code --- services/hilogd/log_persister.cpp | 1 + services/hilogd/log_persister_rotator.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/services/hilogd/log_persister.cpp b/services/hilogd/log_persister.cpp index 4831bfa..93929f6 100644 --- a/services/hilogd/log_persister.cpp +++ b/services/hilogd/log_persister.cpp @@ -59,6 +59,7 @@ LogPersister::LogPersister(uint32_t id, string path, uint32_t fileSize, uint16_t hilogBuffer = &_buffer; compressor = nullptr; buffer = nullptr; + compressBuffer = nullptr; plainLogSize = 0; } diff --git a/services/hilogd/log_persister_rotator.cpp b/services/hilogd/log_persister_rotator.cpp index 407172f..1119300 100644 --- a/services/hilogd/log_persister_rotator.cpp +++ b/services/hilogd/log_persister_rotator.cpp @@ -37,6 +37,7 @@ LogPersisterRotator::LogPersisterRotator(string path, uint32_t fileSize, uint32_ { index = -1; needRotate = true; + memset_s(&info, sizeof(info), 0, sizeof(info)); } LogPersisterRotator::~LogPersisterRotator() -- Gitee