You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "James E. King III (JIRA)" <ji...@apache.org> on 2018/09/16 10:53:00 UTC

[jira] [Resolved] (THRIFT-4620) TZlibTransport.cpp doesn't ensure that there is enough space for the zlib flush marker in the buffer.

     [ https://issues.apache.org/jira/browse/THRIFT-4620?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

James E. King III resolved THRIFT-4620.
---------------------------------------
       Resolution: Fixed
         Assignee: James E. King III
    Fix Version/s: 0.12.0

Committed along with some changes that enable zlib wrapping buffered transport in cpp,go,py,py3 for crosstest.

> TZlibTransport.cpp doesn't ensure that there is enough space for the zlib flush marker in the buffer.
> -----------------------------------------------------------------------------------------------------
>
>                 Key: THRIFT-4620
>                 URL: https://issues.apache.org/jira/browse/THRIFT-4620
>             Project: Thrift
>          Issue Type: Bug
>          Components: C++ - Library
>    Affects Versions: 0.9
>            Reporter: Dominic Coyne
>            Assignee: James E. King III
>            Priority: Major
>              Labels: c++, zlib
>             Fix For: 0.12.0
>
>
> I asked [this question|https://stackoverflow.com/questions/51784225/how-does-thrift-handle-zlib-flush-markers-being-split-over-multiple-messages] on stack overflow related to a crash that I have been getting with Thrift.
> The problem occurs when using TZlibTransport.cpp. After writing to the buffer a few times, we do a flush. If there isn't enough space in cwbuf_ , the Thrift flush marker is split across two messages, which causes an error in the client, as a deflate stream can't start with a partial flush marker, ff.
> Thrift should assure that there will be enough space in the buffer for the complete flush marker, before a deflate.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)