etw: fix descriptors of events 9 and 23
Pull Request check-list
-
Does make -j8 test
(UNIX) orvcbuild test nosign
(Windows) pass with this change (including linting)? -
Is the commit message formatted according to [CONTRIBUTING.md][0]? -
If this change fixes a bug (or a performance problem), is a regression test (or a benchmark) included?
Affected core subsystem(s)
ETW
Description of change
A log of ETW events can be produced with:
logman start NodejsDCS -p NodeJS-ETW-provider -o node_log.etl -ets
:: Do something with node.exe
logman stop NodejsDCS -ets
The resulting etl
file can be open in Event Viewer. However, ETW events 9 and 23 fail to display the EventData
(under the Details tab), having instead a ProcessingErrorData
section with the data in raw hexadecimal. This happens because the events are not generated correctly.
- Event 9: The last event descriptor is a string, but the string is published without the zero terminator. This seems to have been a mistake introduced when reviewing the original pull request, because the original code seems to include the terminator.
- Event 23: The event has no descriptors in the manifest (no
template
attribute), but is generated from node with a dummy integer descriptor, always equal to 0.
There are two commits for easy review, I plan to squash and use the following commit message:
etw: fix descriptors of events 9 and 23
Event 9 must include the string terminator in the last descriptor.
Event 23 must be published with no descriptors, in accordance with
the manifest.
cc @nodejs/platform-windows