Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
L
libzmq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
libzmq
Commits
8d00cdd9
Commit
8d00cdd9
authored
Aug 13, 2016
by
Luca Boccassi
Committed by
GitHub
Aug 13, 2016
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2082 from pijyoi/fix_zmqstream_doc
Problem: zmq_stream doc is confusing regarding ZMQ_SNDMORE flag
parents
2fc86bc3
53402156
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
9 deletions
+4
-9
zmq_socket.txt
doc/zmq_socket.txt
+4
-9
No files found.
doc/zmq_socket.txt
View file @
8d00cdd9
...
...
@@ -406,11 +406,8 @@ When a connection is made, a zero-length message will be received by the
application. Similarly, when the peer disconnects (or the connection is lost),
a zero-length message will be received by the application.
The ZMQ_SNDMORE flag is ignored on data frames. You must send one identity frame
followed by one data frame.
Also, please note that omitting the ZMQ_SNDMORE flag will prevent sending further
data (from any client) on the same socket.
You must send one identity frame followed by one data frame. The ZMQ_SNDMORE
flag is required for identity frames but is ignored on data frames.
[horizontal]
.Summary of ZMQ_STREAM characteristics
...
...
@@ -583,12 +580,10 @@ while (1) {
"Hello, World!";
/* Sends the ID frame followed by the response */
zmq_send (socket, id, id_size, ZMQ_SNDMORE);
zmq_send (socket, http_response, strlen (http_response),
ZMQ_SNDMORE
);
zmq_send (socket, http_response, strlen (http_response),
0
);
/* Closes the connection by sending the ID frame followed by a zero response */
zmq_send (socket, id, id_size, ZMQ_SNDMORE);
zmq_send (socket, 0, 0, ZMQ_SNDMORE);
/* NOTE: If we don't use ZMQ_SNDMORE, then we won't be able to send more */
/* message to any client */
zmq_send (socket, 0, 0, 0);
}
zmq_close (socket);
zmq_ctx_destroy (ctx);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment