This is an archive of the discontinued LLVM Phabricator instance.

[lldb] [Utility] Remove Status::WasInterrupted() along with its only use
ClosedPublic

Authored by mgorny on Oct 15 2021, 1:21 PM.

Details

Summary

Remove Status::WasInterrupted() that checks whether the underlying error
code matches EINTR. ProcessGDBRemote::ConnectToDebugserver() is its
only call site, and it does not seem correct there. After all, EINTR
is precisely when we want to retry, not stop retrying. Furthermore,
it should not really matter since we should be catching EINTR
immediately via llvm::sys::RetryAfterSignal() but that's another story.

Diff Detail

Event Timeline

mgorny requested review of this revision.Oct 15 2021, 1:21 PM
mgorny created this revision.

FTR, this doesn't make ^c work any better or worse.

labath accepted this revision.Oct 18 2021, 12:30 AM

Yeah, random signals should cause a retry (they probably do already) and I think user interrupts should be handled differently (at a higher level).

This revision is now accepted and ready to land.Oct 18 2021, 12:30 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 18 2021, 1:50 AM