Skip to content

Restructure descriptors to support dup() for all descriptor/file types#2242

Merged
stevenengler merged 5 commits intoshadow:mainfrom
stevenengler:restructure-descriptors
Jun 28, 2022
Merged

Restructure descriptors to support dup() for all descriptor/file types#2242
stevenengler merged 5 commits intoshadow:mainfrom
stevenengler:restructure-descriptors

Conversation

@stevenengler
Copy link
Copy Markdown
Contributor

Closes #1648.

The Descriptor type now replaces the CompatDescriptor. The compatibility enum to support C LegacyDescriptors is a new CompatFile type contained within the Descriptor. This restructuring now means that we support dup() and related syscalls for all file descriptors, including for LegacyDescriptors.

@stevenengler stevenengler added Type: Enhancement New functionality or improved design Component: Main Composing the core Shadow executable labels Jun 28, 2022
@stevenengler stevenengler requested a review from sporksmith June 28, 2022 15:19
@stevenengler stevenengler self-assigned this Jun 28, 2022
@github-actions github-actions bot added Component: Build Build/install tools and dependencies Component: Testing Unit and integration tests and frameworks labels Jun 28, 2022
@stevenengler stevenengler removed the request for review from sporksmith June 28, 2022 15:32
@stevenengler stevenengler marked this pull request as draft June 28, 2022 17:28
@stevenengler stevenengler force-pushed the restructure-descriptors branch from 46d2a64 to 944152b Compare June 28, 2022 19:49
@stevenengler stevenengler marked this pull request as ready for review June 28, 2022 20:09
@stevenengler stevenengler requested a review from sporksmith June 28, 2022 20:09
Copy link
Copy Markdown
Contributor

@sporksmith sporksmith left a comment

Choose a reason for hiding this comment

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

Woohoo!

The `Descriptor` type now replaces the `CompatDescriptor`. The compatibility
enum to support C `LegacyDescriptors` is a new `CompatFile` type. This
restructuring now means that we support `dup()` and related syscalls for all
descriptor/file types, including for `LegacyDescriptors`.
@stevenengler stevenengler force-pushed the restructure-descriptors branch from 944152b to 1585a34 Compare June 28, 2022 21:16
@stevenengler stevenengler enabled auto-merge June 28, 2022 21:18
@stevenengler stevenengler merged commit 3f42510 into shadow:main Jun 28, 2022
@stevenengler stevenengler deleted the restructure-descriptors branch June 28, 2022 21:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Component: Build Build/install tools and dependencies Component: Main Composing the core Shadow executable Component: Testing Unit and integration tests and frameworks Type: Enhancement New functionality or improved design

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support fcntl F_DUPFD_CLOEXEC

2 participants