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
c28cbf76
Unverified
Commit
c28cbf76
authored
Feb 03, 2019
by
Simon Giesecke
Committed by
GitHub
Feb 03, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3381 from bluca/test_ipv6_monitor
Problems: ipv6 test_monitor hangs, old Windows build fails
parents
33a493c4
a9a5b2bd
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
8 deletions
+13
-8
.gitignore
.gitignore
+1
-0
zmq.h
include/zmq.h
+3
-0
test_monitor.cpp
tests/test_monitor.cpp
+6
-0
testutil_monitoring.hpp
tests/testutil_monitoring.hpp
+3
-8
No files found.
.gitignore
View file @
c28cbf76
...
@@ -153,6 +153,7 @@ test_proxy_hwm
...
@@ -153,6 +153,7 @@ test_proxy_hwm
unittest_ip_resolver
unittest_ip_resolver
unittest_mtrie
unittest_mtrie
unittest_poller
unittest_poller
unittest_radix_tree
unittest_udp_address
unittest_udp_address
unittest_ypipe
unittest_ypipe
tests/test*.log
tests/test*.log
...
...
include/zmq.h
View file @
c28cbf76
...
@@ -98,6 +98,9 @@ extern "C" {
...
@@ -98,6 +98,9 @@ extern "C" {
#if defined ZMQ_HAVE_SOLARIS || defined ZMQ_HAVE_OPENVMS
#if defined ZMQ_HAVE_SOLARIS || defined ZMQ_HAVE_OPENVMS
#include <inttypes.h>
#include <inttypes.h>
#elif defined _MSC_VER && _MSC_VER < 1600
#elif defined _MSC_VER && _MSC_VER < 1600
#ifndef uint64_t
typedef
unsigned
__int64
uint64_t
;
#endif
#ifndef int32_t
#ifndef int32_t
typedef
__int32
int32_t
;
typedef
__int32
int32_t
;
#endif
#endif
...
...
tests/test_monitor.cpp
View file @
c28cbf76
...
@@ -145,6 +145,12 @@ void test_monitor_versioned_basic (bind_function_t bind_function_,
...
@@ -145,6 +145,12 @@ void test_monitor_versioned_basic (bind_function_t bind_function_,
// Now do a basic ping test
// Now do a basic ping test
bind_function_
(
server
,
server_endpoint
,
sizeof
server_endpoint
);
bind_function_
(
server
,
server_endpoint
,
sizeof
server_endpoint
);
int
ipv6_
;
size_t
ipv6_size_
=
sizeof
(
ipv6_
);
TEST_ASSERT_SUCCESS_ERRNO
(
zmq_getsockopt
(
server
,
ZMQ_IPV6
,
&
ipv6_
,
&
ipv6_size_
));
TEST_ASSERT_SUCCESS_ERRNO
(
zmq_setsockopt
(
client
,
ZMQ_IPV6
,
&
ipv6_
,
sizeof
(
int
)));
TEST_ASSERT_SUCCESS_ERRNO
(
zmq_connect
(
client
,
server_endpoint
));
TEST_ASSERT_SUCCESS_ERRNO
(
zmq_connect
(
client
,
server_endpoint
));
bounce
(
server
,
client
);
bounce
(
server
,
client
);
...
...
tests/testutil_monitoring.hpp
View file @
c28cbf76
...
@@ -32,9 +32,6 @@
...
@@ -32,9 +32,6 @@
#include "testutil.hpp"
#include "testutil.hpp"
#define __STDC_FORMAT_MACROS
#include <inttypes.h>
// General, i.e. non-security specific, monitor utilities
// General, i.e. non-security specific, monitor utilities
// Read one event off the monitor socket; return value and address
// Read one event off the monitor socket; return value and address
...
@@ -261,7 +258,7 @@ int64_t get_monitor_event_with_timeout_v2 (void *monitor_,
...
@@ -261,7 +258,7 @@ int64_t get_monitor_event_with_timeout_v2 (void *monitor_,
char
**
remote_address_
,
char
**
remote_address_
,
int
timeout_
)
int
timeout_
)
{
{
int
res
;
int
64_t
res
;
if
(
timeout_
==
-
1
)
{
if
(
timeout_
==
-
1
)
{
// process infinite timeout in small steps to allow the user
// process infinite timeout in small steps to allow the user
// to see some information on the console
// to see some information on the console
...
@@ -309,10 +306,8 @@ void expect_monitor_event_v2 (void *monitor_,
...
@@ -309,10 +306,8 @@ void expect_monitor_event_v2 (void *monitor_,
expected_remote_address_
?
&
remote_address
:
NULL
);
expected_remote_address_
?
&
remote_address
:
NULL
);
bool
failed
=
false
;
bool
failed
=
false
;
if
(
event
!=
expected_event_
)
{
if
(
event
!=
expected_event_
)
{
fprintf
(
stderr
,
fprintf
(
stderr
,
"Expected monitor event %lld, but received %lld
\n
"
,
"Expected monitor event %"
PRIx64
", but received %"
PRIx64
(
long
long
)
expected_event_
,
(
long
long
)
event
);
"
\n
"
,
expected_event_
,
event
);
failed
=
true
;
failed
=
true
;
}
}
if
(
expected_local_address_
if
(
expected_local_address_
...
...
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