Skip to content

[release/6.0] Fallback to read/write if pread/pwrite fails - #60280

Merged
Anipik merged 13 commits into
release/6.0from
backport/pr-59846-to-release/6.0
Oct 12, 2021
Merged

[release/6.0] Fallback to read/write if pread/pwrite fails#60280
Anipik merged 13 commits into
release/6.0from
backport/pr-59846-to-release/6.0

Conversation

@github-actions

@github-actionsgithub-actionsBot commented Oct 12, 2021

Copy link
Copy Markdown
Contributor

Backport of #59846 to release/6.0.
Fixes#59754

Customer Impact

On Unix, Read/Write to certain special devices e.g: /dev/tty using FIleStream stopped working on 6.0 given that we now use a different syscall for unseekable files.
Our assumption was that such files always reported CanSeek as false, but that turned out to not be true for /dev/tty on macOS.

This change catches the aforementioned error and fallbacks to the syscall that we previously used for seekable and non-seekable files.

Testing

Tested with many other devices that share similarities with /dev/tty:
e.g: /dev/null, /dev/zero, /dev/console, named pipes and socket pairs.

Risk

Low, we are affecting one edge case only which currently is in a regression state.

@ghostghost added the area-System.IO label Oct 12, 2021
@ghost

Copy link
Copy Markdown

Tagging subscribers to this area: @dotnet/area-system-io
See info in area-owners.md if you want to be subscribed.

Issue Details

Backport of #59846 to release/6.0

/cc @jozkee

Customer Impact

Testing

Risk

Author:github-actions[bot]
Assignees:-
Labels:

area-System.IO

Milestone:-

@jozkeejozkee added this to the 6.0.0 milestone Oct 12, 2021
@jozkeejozkee added the Servicing-consider Issue for next servicing release review label Oct 12, 2021
@jozkeejozkee self-assigned this Oct 12, 2021

@tmdstmds left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm

@jeffhandleyjeffhandley left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'm sending to tactics for consideration.

@jeffhandleyjeffhandley added Servicing-approved Approved for servicing release and removed Servicing-consider Issue for next servicing release review labels Oct 12, 2021
@jeffhandley

Copy link
Copy Markdown
Member

Tactics approved for 6.0 GA

@Anipik
Anipik merged commit ca29f93 into release/6.0Oct 12, 2021
@Anipik
Anipik deleted the backport/pr-59846-to-release/6.0 branch October 12, 2021 19:00
@ghostghost locked as resolved and limited conversation to collaborators Nov 11, 2021
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-System.IOServicing-approvedApproved for servicing release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

@jeffhandley@tmds@adamsitnik@Anipik@jozkee