mirror of
https://github.com/zeromq/libzmq.git
synced 2024-12-28 07:58:14 +08:00
5340215613
Solution: fix it. The documentation first states that the ZMQ_SNDMORE flag is ignored on data frames. Then it states that omitting the ZMQ_SNDMORE flag has consequences. The example HTTP server code further muddies the situation with a similar comment. The implementation of ZMQ_STREAM only accepts two-part messages. The first part is an identity frame while the second and last part is the data frame. As with any multipart message, all parts except the last need the ZMQ_SNDMORE flag. The second and last part would normally omit the ZMQ_SNDMORE flag to mark the end of the multipart message. However, the ZMQ_STREAM implementation ignores the ZMQ_SNDMORE flag on the data frame rather than requiring that it be omitted. The latter behaviour would have been more consistent with the other ZeroMQ sockets.