summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite
diff options
context:
space:
mode:
authorPavel Labath <labath@google.com>2017-12-11 09:33:18 +0000
committerPavel Labath <labath@google.com>2017-12-11 09:33:18 +0000
commit390b4879940edd78ab00d535917014df3a43bec4 (patch)
tree752e79318fc6a27cc65926c21ad451038c4abf35 /lldb/packages/Python/lldbsuite
parentad45bf5895182563b2d107e4ecb76d0e340ebd17 (diff)
downloadbcm5719-llvm-390b4879940edd78ab00d535917014df3a43bec4.tar.gz
bcm5719-llvm-390b4879940edd78ab00d535917014df3a43bec4.zip
MainLoop: avoid infinite loop when pty slave gets closed
Summary: For ptys (at least on Linux), the end-of-file (closing of the slave FD) is signalled by the POLLHUP flag. We were ignoring this flag, which meant that when this happened, we would spin in a loop, continuously calling poll(2) and not making any progress. This makes sure we treat POLLHUP as a read event (reading will return 0), and we call the registered callback when it happens. This is the behavior our clients expect (and is consistent with how select(2) works). Reviewers: eugene, beanz Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D41008 llvm-svn: 320345
Diffstat (limited to 'lldb/packages/Python/lldbsuite')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud