-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix EOF (^D) handling in devpts (partially addr #9333) #9336
Fix EOF (^D) handling in devpts (partially addr #9333) #9336
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the fix, and the nice test. One minor nit.
Could you squash the two commits? Otherwise these will appear as two separate commits on the master branch after merge. |
Oh sure, I thought I could squash just before merge. But I'll squash them now and force push. |
bed5b42
to
abb4894
Compare
We don't squash and merge from Github UI (unfortunately...). It needs be go through our internal system (via the "ready to pull" tag). Copybara will clone your PR as a new PR and merge that and close this. And in the process, it just pushes the commits from this branch onto master. So we request the commits are squashed (unless they are meant to be logically separated). |
Make sense. Thanks for the explanation 👌 |
This seems to break the
Full logs here |
abb4894
to
ff0959b
Compare
Oh of course, this behavior is only valid in canonical mode, and that test disables the ICANON flag. Pushed a fix. Edit: commit now passes |
l.masterWaiter.Notify(waiter.ReadableEvents) | ||
} | ||
if !pushed && l.termios.LEnabled(linux.ICANON) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have to hold l.termiosMu
to access l.termios
.
I would set isCanon := l.termios.LEnabled(linux.ICANON)
while the lock is held on line 200, and then reference isCanon
in this conditional.
ff0959b
to
e8c399a
Compare
This is merged! Thanks for the PR. |
This fixes the ctrl-d part of #9333.
Disclaimer: new to this codebase.