Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-1.1
Commits
edb8e509
Commit
edb8e509
authored
Nov 21, 2006
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix the absolute POSIX timer and use it
parent
c7357344
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
10 deletions
+3
-10
src/misc/mtime.c
src/misc/mtime.c
+3
-10
No files found.
src/misc/mtime.c
View file @
edb8e509
...
@@ -242,20 +242,13 @@ void mwait( mtime_t date )
...
@@ -242,20 +242,13 @@ void mwait( mtime_t date )
msleep
(
delay
);
msleep
(
delay
);
#elif defined (HAVE_CLOCK_NANOSLEEP)
#elif defined (HAVE_CLOCK_NANOSLEEP)
# if defined (HAVE_TIMER_ABSTIME_THAT_ACTUALLY_WORKS_WELL)
lldiv_t
d
=
lldiv
(
date
,
1000000
);
lldiv_t
d
=
lldiv
(
date
,
1000000
);
struct
timespec
ts
=
{
d
.
quot
,
d
.
rem
};
struct
timespec
ts
=
{
d
.
quot
,
d
.
rem
*
1000
};
# if (_POSIX_MONOTONIC_CLOCK - 0 >= 0)
# if (_POSIX_MONOTONIC_CLOCK - 0 >= 0)
if
(
clock_nanosleep
(
CLOCK_MONOTONIC
,
TIMER_ABSTIME
,
&
ts
,
NULL
)
)
if
(
clock_nanosleep
(
CLOCK_MONOTONIC
,
TIMER_ABSTIME
,
&
ts
,
NULL
)
)
# endif
# endif
clock_nanosleep
(
CLOCK_REALTIME
,
TIMER_ABSTIME
,
&
ts
,
NULL
);
clock_nanosleep
(
CLOCK_REALTIME
,
TIMER_ABSTIME
,
&
ts
,
NULL
);
# else
date
-=
mdate
();
if
(
date
<=
0
)
return
;
msleep
(
date
);
# endif
#else
#else
struct
timeval
tv_date
;
struct
timeval
tv_date
;
...
...
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