Skip to content

Update Microsoft.Diagnostics.Tracing.TraceEvent to version 3.1.23 to fix P/Invoke buffer handling #5523

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 14, 2025

Conversation

Copilot
Copy link
Contributor

@Copilot Copilot AI commented Jul 14, 2025

This PR updates the Microsoft.Diagnostics.Tracing.TraceEvent library from version 3.1.21 to 3.1.23 to incorporate the fix for an off-by-one error in buffer handling during P/Invoke operations.

Changes Made

  • Updated MicrosoftDiagnosticsTracingTraceEventVersion from 3.1.21 to 3.1.23 in eng/Versions.props

Tools Affected

This centralized version update automatically applies to all diagnostic tools that use the TraceEvent library:

  • dotnet-stack (specifically mentioned in the issue)
  • dotnet-gcdump (specifically mentioned in the issue)
  • dotnet-counters
  • dotnet-trace
  • dotnet-dsrouter

Note: dotnet-dump does not directly reference the TraceEvent library, so it is not affected by this change.

Background

The fix addresses a critical off-by-one error in buffer handling during P/Invoke operations that was resolved in TraceEvent version 3.1.23. This issue was originally reported and fixed in microsoft/perfview#2226.

By updating to the latest version, all affected diagnostic tools will now benefit from this important stability fix.

Fixes #5508.

Warning

Firewall rules blocked me from connecting to one or more addresses

I tried to connect to the following addresses, but was blocked by firewall rules:

  • kijvsblobprodcus387.vsblob.vsassets.io
    • Triggering command: dotnet restore src/Tools/dotnet-stack/dotnet-stack.csproj (dns block)

If you need me to access, download, or install something from one of these locations, you can either:


💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.

@Copilot Copilot AI changed the title [WIP] Off-by-one error in buffer handling during P/Invoke Update Microsoft.Diagnostics.Tracing.TraceEvent to version 3.1.23 to fix P/Invoke buffer handling Jul 14, 2025
@Copilot Copilot AI requested a review from hoyosjs July 14, 2025 18:33
Copilot finished work on behalf of hoyosjs July 14, 2025 18:33
@hoyosjs hoyosjs marked this pull request as ready for review July 14, 2025 18:46
@hoyosjs hoyosjs requested a review from a team July 14, 2025 18:47
@hoyosjs hoyosjs enabled auto-merge (squash) July 14, 2025 18:56
@steveisok steveisok self-requested a review July 14, 2025 20:04
@hoyosjs hoyosjs merged commit 3d11b96 into main Jul 14, 2025
19 checks passed
@hoyosjs hoyosjs deleted the copilot/fix-5508 branch July 14, 2025 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Off-by-one error in buffer handling during P/Invoke
5 participants