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
1adb7b10
Commit
1adb7b10
authored
May 29, 2012
by
Pieter Hintjens
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #352 from hurtonm/issue_370
Fix issue #370
parents
f7bd543c
7fe45af3
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
3 deletions
+15
-3
req.cpp
src/req.cpp
+5
-0
req.hpp
src/req.hpp
+1
-0
session_base.cpp
src/session_base.cpp
+8
-3
session_base.hpp
src/session_base.hpp
+1
-0
No files found.
src/req.cpp
View file @
1adb7b10
...
@@ -178,3 +178,8 @@ int zmq::req_session_t::write (msg_t *msg_)
...
@@ -178,3 +178,8 @@ int zmq::req_session_t::write (msg_t *msg_)
return
-
1
;
return
-
1
;
}
}
void
zmq
::
req_session_t
::
reset
()
{
session_base_t
::
reset
();
state
=
identity
;
}
src/req.hpp
View file @
1adb7b10
...
@@ -72,6 +72,7 @@ namespace zmq
...
@@ -72,6 +72,7 @@ namespace zmq
// Overloads of the functions from session_base_t.
// Overloads of the functions from session_base_t.
int
write
(
msg_t
*
msg_
);
int
write
(
msg_t
*
msg_
);
void
reset
();
private
:
private
:
...
...
src/session_base.cpp
View file @
1adb7b10
...
@@ -190,6 +190,13 @@ int zmq::session_base_t::write (msg_t *msg_)
...
@@ -190,6 +190,13 @@ int zmq::session_base_t::write (msg_t *msg_)
return
-
1
;
return
-
1
;
}
}
void
zmq
::
session_base_t
::
reset
()
{
// Restore identity flags.
send_identity
=
options
.
send_identity
;
recv_identity
=
options
.
recv_identity
;
}
void
zmq
::
session_base_t
::
flush
()
void
zmq
::
session_base_t
::
flush
()
{
{
if
(
pipe
)
if
(
pipe
)
...
@@ -388,9 +395,7 @@ void zmq::session_base_t::detached ()
...
@@ -388,9 +395,7 @@ void zmq::session_base_t::detached ()
return
;
return
;
}
}
// Restore identity flags.
reset
();
send_identity
=
options
.
send_identity
;
recv_identity
=
options
.
recv_identity
;
// Reconnect.
// Reconnect.
if
(
options
.
reconnect_ivl
!=
-
1
)
if
(
options
.
reconnect_ivl
!=
-
1
)
...
...
src/session_base.hpp
View file @
1adb7b10
...
@@ -56,6 +56,7 @@ namespace zmq
...
@@ -56,6 +56,7 @@ namespace zmq
// Following functions are the interface exposed towards the engine.
// Following functions are the interface exposed towards the engine.
virtual
int
read
(
msg_t
*
msg_
);
virtual
int
read
(
msg_t
*
msg_
);
virtual
int
write
(
msg_t
*
msg_
);
virtual
int
write
(
msg_t
*
msg_
);
virtual
void
reset
();
void
flush
();
void
flush
();
void
detach
();
void
detach
();
...
...
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