Skip to content

fix(metadata): import ACCESS_ALLOWED_ACE_TYPE from SystemServices (#1866) - #3544

Merged
oferchen merged 1 commit into
masterfrom
fix/windows-acl-import-1866
May 1, 2026
Merged

oferchen merged 1 commit into
masterfrom
fix/windows-acl-import-1866

Conversation

@oferchen

@oferchen oferchen commented May 1, 2026

Copy link
Copy Markdown
Owner

Summary

  • Fixes the master Windows build break introduced by Handle cargo-rpm absence before profile validation #1866.
  • windows-rs 0.62.2 exports `ACCESS_ALLOWED_ACE_TYPE` (the ACE-type discriminant byte, value 0x0) under `windows::Win32::System::SystemServices`, not `windows::Win32::Security` where the same-named struct `ACCESS_ALLOWED_ACE` lives. The original import in Handle cargo-rpm absence before profile validation #1866 placed both names in the Security group, which fails to resolve and breaks every Windows CI job on master.
  • Unblocks Windows CI on every open PR currently rebased onto master.

Why this is correct

  • `windows-rs 0.62.2` source: `src/Windows/Win32/Security/mod.rs` defines the `ACCESS_ALLOWED_ACE` struct; `src/Windows/Win32/System/SystemServices/mod.rs` defines `pub const ACCESS_ALLOWED_ACE_TYPE: u32 = 0u32;`.
  • All in-file usages cast through `as u8` already (e.g. `acl_windows.rs:321`), so the constant width does not change.
  • upstream: `WinNT.h` declares `ACCESS_ALLOWED_ACE_TYPE (0x0)`.

Test plan

  • Local edit verified against windows-rs 0.62.2 vendored source.
  • CI Windows (stable) green
  • CI Windows (beta) green
  • CI Windows (nightly) green
  • CI Windows GNU cross-check green
  • fmt+clippy green

)

windows-rs 0.62.2 exports ACCESS_ALLOWED_ACE_TYPE (the ACE-type
discriminant byte, value 0x0) under windows::Win32::System::SystemServices,
not under windows::Win32::Security where ACCESS_ALLOWED_ACE (the struct)
lives. The original import in #1866 placed both names in the Security
group, which fails to resolve and breaks every Windows CI job on master.

upstream: WinNT.h
@oferchen
oferchen merged commit 3a8c64f into master May 1, 2026
14 checks passed
@github-actions github-actions Bot added the bug Something isn't working label May 1, 2026
@oferchen
oferchen deleted the fix/windows-acl-import-1866 branch May 2, 2026 03:49
oferchen added a commit that referenced this pull request May 5, 2026
…1866)

PR #3544 moved the ACCESS_ALLOWED_ACE_TYPE import to
windows::Win32::System::SystemServices to match windows-rs 0.62, but did
not add the corresponding Cargo feature to Cargo.toml. This left the
import unresolved on Windows targets:

  error[E0432]: unresolved import `windows::Win32::System::SystemServices`
   --> crates/metadata/src/acl_windows.rs:67:30
    |
  67 | use windows::Win32::System::SystemServices::ACCESS_ALLOWED_ACE_TYPE;
    |                              ^^^^^^^^^^^^^^ could not find `SystemServices` in `System`
    |
    = note: the item is gated behind the `Win32_System_SystemServices` feature

Add the missing feature to the windows-rs dependency declaration so the
ACL code compiles on all Windows toolchains (stable/beta/nightly/GNU).

Unblocks: master CI (Windows stable required check), all 11 open PRs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant