[ https://issues.apache.org/jira/browse/THRIFT-3238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15213522#comment-15213522 ]
Ted Wang commented on THRIFT-3238: ---------------------------------- I went with the option to wrap beginAsyncRead with a try/catch block. It's not the prettiest solution, but I think it is a simple solution that meets the two most important criteria to me: 1. The error is reported and not discarded. readOverlap_ still has the error info for this error so the next call to TPipe::read() -> TPipe::endAsyncRead() -> TOverlappedWorkItem::overlappedResults() will report the error. 2. The error is reported to the connected client, not the server. > Fix TNamedPipeServer can be interrupted by faulty client > -------------------------------------------------------- > > Key: THRIFT-3238 > URL: https://issues.apache.org/jira/browse/THRIFT-3238 > Project: Thrift > Issue Type: Bug > Components: C++ - Library > Affects Versions: 0.9.2 > Environment: Windows > Reporter: Paweł Janicki > Priority: Critical > Attachments: > 0001-Fix-TNamedPipeServer-can-be-interrupted-by-faulty-cl.patch, > 0002-THRIFT-3238.-cpp-Fix-TNamedPipeServer-can-be-interru.patch > > > A faulty or hostile client can cause TNamedPipeServer to be interrupted and > return from serve(). The client that causes such effect just needs to open > and immediately close TPipe transport. > Caused by not handling some NamedPipe error codes. -- This message was sent by Atlassian JIRA (v6.3.4#6332)