Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-1941

PHP Serializer deserialize doesn't work

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • PHP - Library
    • None
    • Patch Available

    Description

      The deserialize function in TBinarySerializer.php writes a message header to the transport and then tries to deserialize the thrift object. Because the TBinaryProtocolAccelerated class requires a TBufferedTransport it wraps it. The result is that the written message header is in the write buffer of the transport and when the desializer tries to read the data it doesn't get the message header because its only in the write buffer. Calling flush on the transport explicitly after writing the message header fixes the issue.

      Attachments

        1. thrift-1941.patch
          1 kB
          Nathaniel Cook

        Activity

          People

            Unassigned Unassigned
            nvcook42 Nathaniel Cook
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: