[lldb] Fix TestProcessIOHandlerInterrupt.py for macos
authorPavel Labath <pavel@labath.sk>
Fri, 18 Mar 2022 10:47:47 +0000 (11:47 +0100)
committerPavel Labath <pavel@labath.sk>
Fri, 18 Mar 2022 10:51:55 +0000 (11:51 +0100)
commita4d6de2031ad2f92d399fc8d1b1301229ed8255b
tree9a5003bb475db264c7c89cdd0f84f6a24c2d9214
parentfee94803f59dbd1a5b39c51036f181246d7d2fe6
[lldb] Fix TestProcessIOHandlerInterrupt.py for macos

On darwin, we don't completely suppress the signal used to interrupt the
inferior. The underlying read syscall returns EINTR, which causes premature
termination of the input loop.

Work around that by hand-rolling an EINTR-resistant version of getline.
lldb/test/API/iohandler/sigint/cat.cpp