mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-16 06:59:55 -05:00
add pa_timespec_reset()
git-svn-id: file:///home/lennart/svn/public/pulseaudio/branches/lennart@1726 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
747b01be94
commit
6817987116
2 changed files with 8 additions and 0 deletions
|
|
@ -46,6 +46,13 @@ struct timespec *pa_timespec_store(struct timespec *a, pa_usec_t u) {
|
||||||
return a;
|
return a;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
struct timespec *pa_timespec_reset(struct timespec *a) {
|
||||||
|
pa_assert(a);
|
||||||
|
|
||||||
|
a->tv_sec = a->tv_nsec = 0;
|
||||||
|
return a;
|
||||||
|
}
|
||||||
|
|
||||||
pa_usec_t pa_timespec_load(struct timespec *ts) {
|
pa_usec_t pa_timespec_load(struct timespec *ts) {
|
||||||
pa_assert(ts);
|
pa_assert(ts);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -37,6 +37,7 @@ pa_usec_t pa_rtclock_age(const struct timespec *tv);
|
||||||
int pa_rtclock_hrtimer(void);
|
int pa_rtclock_hrtimer(void);
|
||||||
|
|
||||||
struct timespec *pa_timespec_store(struct timespec *a, pa_usec_t u);
|
struct timespec *pa_timespec_store(struct timespec *a, pa_usec_t u);
|
||||||
|
struct timespec *pa_timespec_reset(struct timespec *a);
|
||||||
pa_usec_t pa_timespec_load(struct timespec *tv);
|
pa_usec_t pa_timespec_load(struct timespec *tv);
|
||||||
struct timespec *pa_timespec_add(struct timespec *tv, pa_usec_t t);
|
struct timespec *pa_timespec_add(struct timespec *tv, pa_usec_t t);
|
||||||
pa_usec_t pa_timespec_diff(const struct timespec *a, const struct timespec *b);
|
pa_usec_t pa_timespec_diff(const struct timespec *a, const struct timespec *b);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue