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
80942656
Commit
80942656
authored
Feb 29, 2024
by
Dridi Boukelmoune
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vtim: VTIM_timeval() for socket timeouts
parent
d2cbad5e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
vtim.h
include/vtim.h
+1
-0
vtim.c
lib/libvarnish/vtim.c
+7
-0
No files found.
include/vtim.h
View file @
80942656
...
...
@@ -40,4 +40,5 @@ vtim_real VTIM_real(void);
void
VTIM_sleep
(
vtim_dur
t
);
struct
timespec
VTIM_timespec
(
vtim_dur
t
);
struct
timeval
VTIM_timeval
(
vtim_dur
t
);
struct
timeval
VTIM_timeval_sock
(
vtim_dur
t
);
int
VTIM_poll_tmo
(
vtim_dur
);
lib/libvarnish/vtim.c
View file @
80942656
...
...
@@ -454,6 +454,13 @@ VTIM_timespec(vtim_dur t)
return
(
tv
);
}
struct
timeval
VTIM_timeval_sock
(
vtim_dur
t
)
{
return
(
VTIM_timeval
(
isinf
(
t
)
?
0
.
:
vmax
(
t
,
1e-3
)));
}
int
VTIM_poll_tmo
(
vtim_dur
tmo
)
{
...
...
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