[Lldb-commits] [PATCH] Fix ProcessIO test failures
jingham at apple.com
jingham at apple.com
Wed Mar 11 10:40:45 PDT 2015
> On Mar 11, 2015, at 10:00 AM, Pavel Labath <labath at google.com> wrote:
>
> InterruptRead is already implemented, here I have only added pure virtual method to the superclass, so they can be accessed easily. For implementations, refer to source/Host/posix/ConnectionFileDescriptorPosix.cpp and source/Host/windows/ConnectionGenericFileWindows.cpp.
Ah, cool.
>
>> It seems like you are saying InterruptRead will consume all available stdout, then return Interrupted, which is a little odd for an interrupt.
>
>
> Yes that is basically what I am saying. Maybe "interrupt" is not exactly the best name for this, but it was already present, so I used it. In the general case, this is exactly what InterruptRead will do though - make the thread blocked on Read() return immediately with eConnectionStatusInterrupted. In this comment, I have just tried to explain what happens in the edge case, when there is input readily available *and* you call InterruptRead() - here, the priority is given to reading the input.
Maybe Synchronize would be better for your usage, since that is what you really intend. This only gets used in the EditLine interface so far as I can see, and I'm not sure what the semantics there are supposed to be.
Jim
>
>
> http://reviews.llvm.org/D8246
>
> EMAIL PREFERENCES
> http://reviews.llvm.org/settings/panel/emailpreferences/
>
>
More information about the lldb-commits
mailing list