kmaki565 / EventLook

A fast & handy alternative to Windows Event Viewer
MIT License
63 stars 12 forks source link

Crash when accessing xml of an event deleted from system #72

Closed kmaki565 closed 2 months ago

kmaki565 commented 2 months ago

This is a side effect of #69. It is possible that the app cannot retrieve XML of an event when the event does not exist actually since EventItem.GetXml() method queries the corresponding event from the system when the user actually clicks on the event. I encounter this issue when System event log was full and new events came in after opening the app (a rogue service program outputs logs very often on my system).
image

The app should handle the exception and skip highlighting the (invalid) xml string.

kmaki565 commented 2 months ago

@Ceus , can you support to fix this? You can easily repro if you "Clear Log" on any event log you think is safe to clear after opening the log in the app.

image

kmaki565 commented 2 months ago

Fixed by #73