Skip to content

Fix sizeof typo in MessageWriter::GetRelativeIndex#40276

Merged
benhillis merged 1 commit intomasterfrom
fix/message-sizeof-typo
Apr 22, 2026
Merged

Fix sizeof typo in MessageWriter::GetRelativeIndex#40276
benhillis merged 1 commit intomasterfrom
fix/message-sizeof-typo

Conversation

@benhillis
Copy link
Copy Markdown
Member

sizeof(index) incorrectly resolved to a C library function type (::index from <strings.h>) instead of the Index parameter, causing a build error on Linux:

message.h(174,60): error G62009F68: invalid application of 'sizeof' to a function type

Fix: sizeof(index)sizeof(Index) to match the parameter name.

Introduced in 58bd525 (#40197).

@benhillis benhillis requested a review from a team as a code owner April 22, 2026 21:15
Copilot AI review requested due to automatic review settings April 22, 2026 21:15
sizeof(index) incorrectly resolved to a C library function type instead
of the Index parameter, causing a build error on Linux. Fix the casing
to match the parameter name.

Introduced in 58bd525 (#40197).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@benhillis benhillis force-pushed the fix/message-sizeof-typo branch from 0bc67a7 to 036e6a9 Compare April 22, 2026 21:16
@benhillis benhillis enabled auto-merge (squash) April 22, 2026 21:19
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses a Linux build break in wsl::shared::MessageWriter::GetRelativeIndex() caused by sizeof(index) binding to the POSIX ::index symbol, and also includes several test/dependency updates related to kernel/9p behavior.

Changes:

  • Fix MessageWriter::GetRelativeIndex to use sizeof(Index) (the function parameter) to restore Linux builds.
  • Update kernel package version and adjust tests for updated 9p mount option formatting / filesystem behavior.
  • Increase mirrored networking stabilization timeout and add richer diagnostics in the mirrored networking tests.

Reviewed changes

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/shared/inc/message.h Fix sizeof(index) typo by referencing the correct Index parameter.
packages.config Update Microsoft.WSL.Kernel package version.
test/windows/UnitTests.cpp Update expected GPU 9p mount options string (cache=0x5).
test/windows/NetworkTests.cpp Add interface-level logging during mirrored-state wait and extend watchdog timeout.
test/linux/unit_tests/lxtfs.c Update expected 9p mount option formatting and adjust writev test expectations.
test/linux/unit_tests/eventfd.c Write/read only the uint64_t payload size for eventfd validation.

@benhillis benhillis merged commit 552a9cd into master Apr 22, 2026
9 checks passed
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.

3 participants