0
0
mirror of https://github.com/zeromq/libzmq.git synced 2024-12-28 07:58:14 +08:00

Merge pull request #40 from hintjens/master

Backported fix for #763
This commit is contained in:
Pieter Hintjens 2013-12-01 02:55:48 -08:00
commit 97e1ecce22
3 changed files with 18 additions and 1 deletions

10
NEWS
View File

@ -1,3 +1,13 @@
0MQ version 4.0.4 stable, released on 2013/xx/xx
================================================
Bug Fixes
---------
* Fixed #763; when talking to a ZMTP v1 peer (libzmq 2.2), a socket would
send an extra identity frame at the start of the connection.
0MQ version 4.0.3 stable, released on 2013/11/24
================================================

View File

@ -31,7 +31,7 @@
/* Version macros for compile-time API version detection */
#define ZMQ_VERSION_MAJOR 4
#define ZMQ_VERSION_MINOR 0
#define ZMQ_VERSION_PATCH 3
#define ZMQ_VERSION_PATCH 4
#define ZMQ_MAKE_VERSION(major, minor, patch) \
((major) * 10000 + (minor) * 100 + (patch))

View File

@ -507,6 +507,13 @@ bool zmq::stream_engine_t::handshake ()
// message into the incoming message stream.
if (options.type == ZMQ_PUB || options.type == ZMQ_XPUB)
subscription_required = true;
// We are sending our identity now and the next message
// will come from the socket.
read_msg = &stream_engine_t::pull_msg_from_session;
// We are expecting identity message.
write_msg = &stream_engine_t::write_identity;
}
else
if (greeting_recv [revision_pos] == ZMTP_1_0) {