Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
LARN
PRRT
Commits
4c5163df
Commit
4c5163df
authored
Sep 04, 2018
by
rna
Browse files
SO_REUSEADDR for all versions.
parent
91691297
Pipeline
#2979
passed with stages
in 3 minutes and 42 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
prrt/time-protocol.h
View file @
4c5163df
...
...
@@ -77,9 +77,10 @@ static inline socket_t _open_receiver(struct arguments *args)
int
ssock
=
socket
(
AF_INET
,
SOCK_STREAM
,
0
);
assert
(
ssock
>=
0
);
int
yes
=
1
;
setsockopt
(
ssock
,
SOL_SOCKET
,
SO_REUSEADDR
,
&
yes
,
sizeof
(
yes
));
if
(
args
->
optimized
)
{
int
yes
=
1
;
setsockopt
(
ssock
,
SOL_SOCKET
,
SO_REUSEADDR
,
&
yes
,
sizeof
(
yes
));
setsockopt
(
ssock
,
SOL_TCP
,
TCP_QUICKACK
,
&
yes
,
sizeof
(
yes
));
int
recv_buffer_size
=
args
->
rcvbuf
;
...
...
Write
Preview
Supports
Markdown
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