mirror of
https://github.com/openharmony/drivers_liteos.git
synced 2026-07-19 10:47:24 -04:00
Description:[feature] support flush hievent interface
Change-Id: I228c8e8845e175b53f2c8b9f77dc64ec1d3a26a9 Signed-off-by: shenchenkai <shenchenkai@huawei.com>
This commit is contained in:
@@ -57,5 +57,6 @@ int HiviewHieventSetTime(struct HiviewHievent *event, long long seconds);
|
||||
int HiviewHieventAddFilePath(struct HiviewHievent *event, const char *path);
|
||||
int HiviewHieventReport(struct HiviewHievent *obj);
|
||||
void HiviewHieventDestroy(struct HiviewHievent *event);
|
||||
void HiviewHieventFlush(void);
|
||||
|
||||
#endif /* HIVIEW_HIEVENT_H */
|
||||
|
||||
@@ -543,3 +543,11 @@ void HiviewHieventDestroy(struct HiviewHievent *event)
|
||||
}
|
||||
LOS_MemFree((VOID *)OS_SYS_MEM_ADDR, event);
|
||||
}
|
||||
|
||||
void HiviewHieventFlush(void)
|
||||
{
|
||||
// magic number 0x7BBE69BD for notify hiview to flush hievent file
|
||||
struct HiviewHievent *hievent = HiviewHieventCreate(0x7BBE69BD);
|
||||
HiviewHieventReport(hievent);
|
||||
HiviewHieventDestroy(hievent);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user