Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
e600a75e
Commit
e600a75e
authored
Oct 13, 2011
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Work around a Solaris bug.
Submitted by: Nils Goroll
parent
69e59af2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
vtcp.c
lib/libvarnish/vtcp.c
+7
-1
No files found.
lib/libvarnish/vtcp.c
View file @
e600a75e
...
...
@@ -265,7 +265,13 @@ VTCP_set_read_timeout(int s, double seconds)
timeout
.
tv_sec
=
(
int
)
floor
(
seconds
);
timeout
.
tv_usec
=
(
int
)(
1e6
*
(
seconds
-
timeout
.
tv_sec
));
#ifdef SO_RCVTIMEO_WORKS
AZ
(
setsockopt
(
s
,
SOL_SOCKET
,
SO_RCVTIMEO
,
&
timeout
,
sizeof
timeout
));
/*
* Solaris bug (present at least in snv_151 and older): If this fails
* with EINVAL, the socket is half-closed (SS_CANTSENDMORE) and the
* timeout does not get set. Needs to be fixed in Solaris, there is
* nothing we can do about this.
*/
VTCP_Assert
(
setsockopt
(
s
,
SOL_SOCKET
,
SO_RCVTIMEO
,
&
timeout
,
sizeof
timeout
));
#else
(
void
)
s
;
#endif
...
...
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