[lldb] Add missing EINTR handling

Differential Revision: https://reviews.llvm.org/D59606

llvm-svn: 356703
This commit is contained in:
Michal Gorny
2019-03-21 19:35:55 +00:00
parent c56872589f
commit 2819136f0a
15 changed files with 52 additions and 26 deletions

View File

@@ -665,7 +665,8 @@ Status NativeProcessNetBSD::Attach() {
int wstatus;
// Need to use WALLSIG otherwise we receive an error with errno=ECHLD At this
// point we should have a thread stopped if waitpid succeeds.
if ((wstatus = waitpid(m_pid, NULL, WALLSIG)) < 0)
if ((wstatus = llvm::sys::RetryAfterSignal(-1, waitpid,
m_pid, NULL, WALLSIG)) < 0)
return Status(errno, eErrorTypePOSIX);
/* Initialize threads */