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
2e06737b
Commit
2e06737b
authored
Apr 28, 2015
by
Martin Hurton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pub: Don't delay pipe termination
parent
09a65c55
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
0 deletions
+14
-0
pub.cpp
src/pub.cpp
+13
-0
pub.hpp
src/pub.hpp
+1
-0
No files found.
src/pub.cpp
View file @
2e06737b
...
...
@@ -18,6 +18,8 @@
*/
#include "pub.hpp"
#include "pipe.hpp"
#include "err.hpp"
#include "msg.hpp"
zmq
::
pub_t
::
pub_t
(
class
ctx_t
*
parent_
,
uint32_t
tid_
,
int
sid_
)
:
...
...
@@ -30,6 +32,17 @@ zmq::pub_t::~pub_t ()
{
}
void
zmq
::
pub_t
::
xattach_pipe
(
pipe_t
*
pipe_
,
bool
subscribe_to_all_
)
{
zmq_assert
(
pipe_
);
// Don't delay pipe termination as there is no one
// to receive the delimiter.
pipe_
->
set_nodelay
();
xpub_t
::
xattach_pipe
(
pipe_
,
subscribe_to_all_
);
}
int
zmq
::
pub_t
::
xrecv
(
class
msg_t
*
)
{
// Messages cannot be received from PUB socket.
...
...
src/pub.hpp
View file @
2e06737b
...
...
@@ -38,6 +38,7 @@ namespace zmq
~
pub_t
();
// Implementations of virtual functions from socket_base_t.
void
xattach_pipe
(
zmq
::
pipe_t
*
pipe_
,
bool
subscribe_to_all_
=
false
);
int
xrecv
(
zmq
::
msg_t
*
msg_
);
bool
xhas_in
();
...
...
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