Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
labs
BIRD Internet Routing Daemon
Commits
861f223a
Commit
861f223a
authored
Jan 06, 2010
by
Ondřej Zajíček
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BSD compatibility fix.
parent
0c75411b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
10 deletions
+4
-10
sysdep/unix/io.c
sysdep/unix/io.c
+4
-10
No files found.
sysdep/unix/io.c
View file @
861f223a
...
...
@@ -492,10 +492,6 @@ tm_format_reltime(char *x, bird_clock_t t)
#define SOL_IPV6 IPPROTO_IPV6
#endif
#ifndef IPV6_ADD_MEMBERSHIP
#define IPV6_ADD_MEMBERSHIP IP_ADD_MEMBERSHIP
#endif
static
list
sock_list
;
static
struct
birdsock
*
current_sock
;
static
struct
birdsock
*
stored_sock
;
...
...
@@ -842,10 +838,9 @@ sk_join_group(sock *s, ip_addr maddr)
mreq
.
ipv6mr_interface
=
s
->
iface
->
index
;
#endif
/* RFC 2553 says IPV6_JOIN_GROUP */
if
(
setsockopt
(
s
->
fd
,
SOL_IPV6
,
IPV6_ADD_MEMBERSHIP
,
&
mreq
,
sizeof
(
mreq
))
<
0
)
if
(
setsockopt
(
s
->
fd
,
SOL_IPV6
,
IPV6_JOIN_GROUP
,
&
mreq
,
sizeof
(
mreq
))
<
0
)
{
log
(
L_ERR
"sk_join_group: IPV6_
ADD_MEMBERSHI
P: %m"
);
log
(
L_ERR
"sk_join_group: IPV6_
JOIN_GROU
P: %m"
);
return
-
1
;
}
...
...
@@ -865,10 +860,9 @@ sk_leave_group(sock *s, ip_addr maddr)
mreq
.
ipv6mr_interface
=
s
->
iface
->
index
;
#endif
/* RFC 2553 says IPV6_LEAVE_GROUP */
if
(
setsockopt
(
s
->
fd
,
SOL_IPV6
,
IPV6_DROP_MEMBERSHIP
,
&
mreq
,
sizeof
(
mreq
))
<
0
)
if
(
setsockopt
(
s
->
fd
,
SOL_IPV6
,
IPV6_LEAVE_GROUP
,
&
mreq
,
sizeof
(
mreq
))
<
0
)
{
log
(
L_ERR
"sk_leave_group: IPV6_
DROP_MEMBERSHI
P: %m"
);
log
(
L_ERR
"sk_leave_group: IPV6_
LEAVE_GROU
P: %m"
);
return
-
1
;
}
...
...
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