Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ISC Open Source Projects
Kea
Commits
22767526
Commit
22767526
authored
Sep 05, 2011
by
Tomek Mrugalski
🛰
Browse files
[1186] Tests are now working on OS X.
parent
54ba29f0
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/bin/dhcp6/tests/iface_mgr_unittest.cc
View file @
22767526
...
...
@@ -71,9 +71,11 @@ TEST_F(IfaceMgrTest, loDetect) {
NakedIfaceMgr
*
ifacemgr
=
new
NakedIfaceMgr
();
IOAddress
loAddr
(
"::1"
);
IOAddress
mcastAddr
(
"ff02::1:2"
);
// bind multicast socket to port 10547
int
socket1
=
ifacemgr
->
openSocket
(
"lo"
,
loAddr
,
10547
);
int
socket1
=
ifacemgr
->
openSocket
(
"lo"
,
mcastAddr
,
10547
);
// this fails on BSD (there's no lo interface there)
// poor man's interface dection
// it will go away as soon as proper interface detection
...
...
@@ -82,7 +84,8 @@ TEST_F(IfaceMgrTest, loDetect) {
cout
<<
"This is Linux, using lo as loopback."
<<
endl
;
close
(
socket1
);
}
else
{
socket1
=
ifacemgr
->
openSocket
(
"lo0"
,
loAddr
,
10547
);
// this fails on Linux and succeeds on BSD
socket1
=
ifacemgr
->
openSocket
(
"lo0"
,
mcastAddr
,
10547
);
if
(
socket1
>
0
)
{
sprintf
(
LOOPBACK
,
"lo0"
);
cout
<<
"This is BSD, using lo0 as loopback."
<<
endl
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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