未验证 提交 d914ea37 编写于 作者: O openharmony_ci 提交者: Gitee

!57 hievent在特定情况下死循环,导致模块以及所有依赖的进程卡住,系统DoS

Merge pull request !57 from honghecun/monthly_20221018
......@@ -255,7 +255,7 @@ static void HieventCoverOldLog(size_t bufLen)
struct HieventEntry header;
size_t totalSize = bufLen + sizeof(struct HieventEntry);
while (totalSize + g_hieventDev.size >= HIEVENT_LOG_BUFFER) {
while (totalSize + g_hieventDev.size > HIEVENT_LOG_BUFFER) {
retval = HieventReadRingBuffer((unsigned char *)&header, sizeof(header));
if (retval < 0) {
break;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册