Skip to content

Linux: add name_to_handle_at and open_by_handle_at#4988

Open
samu698 wants to merge 1 commit intorust-lang:mainfrom
samu698:main
Open

Linux: add name_to_handle_at and open_by_handle_at#4988
samu698 wants to merge 1 commit intorust-lang:mainfrom
samu698:main

Conversation

@samu698
Copy link

@samu698 samu698 commented Feb 21, 2026

Description

Add file handle operations for Linux.

In particular I added:

  • name_to_handle_at()
  • open_by_handle_at()
  • file_handle
  • MAX_HANDLE_SZ
  • AT_HANDLE_MNT_ID_UNIQUE
  • AT_HANDLE_FID
  • AT_HANDLE_CONNECTABLE

Sources

Checklist

  • Relevant tests in libc-test/semver have been updated
  • No placeholder or unstable values like *LAST or *MAX are
    included (see #3131)
  • Tested locally (cd libc-test && cargo test --target mytarget);
    especially relevant for platforms that may not be checked in CI

@rustbot label +stable-nominated

@rustbot rustbot added S-waiting-on-review stable-nominated This PR should be considered for cherry-pick to libc's stable release branch labels Feb 21, 2026
@samu698 samu698 marked this pull request as draft February 21, 2026 14:01
@samu698 samu698 force-pushed the main branch 3 times, most recently from 2699446 to c343e34 Compare February 21, 2026 18:26
@samu698 samu698 marked this pull request as ready for review February 22, 2026 00:55
Copy link
Contributor

@tgross35 tgross35 left a comment

Choose a reason for hiding this comment

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

One nit then LGTM

View changes since this review

@rustbot
Copy link
Collaborator

rustbot commented Mar 2, 2026

Reminder, once the PR becomes ready for a review, use @rustbot ready.

@samu698
Copy link
Author

samu698 commented Mar 2, 2026

Ok, thanks for the suggestion, now I am skipping only the file_handle.f_handle field for musl targets where it is a flexible array member.

@rustbot ready

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review stable-nominated This PR should be considered for cherry-pick to libc's stable release branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants