mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-29 05:40:25 -04:00
Add struct timeval and timespec definition when _POSIX_C_SOURCE is not defined
FIXME: It might cause problems on some platforms when tv_usec is not long type.
This commit is contained in:
parent
7668e264af
commit
8c9e4114a2
1 changed files with 12 additions and 0 deletions
|
|
@ -130,6 +130,18 @@ int snd_shm_area_destroy(struct snd_shm_area *area);
|
|||
|
||||
int snd_user_file(const char *file, char **result);
|
||||
|
||||
#ifndef _POSIC_C_SOURCE
|
||||
struct timeval {
|
||||
time_t tv_sec; /* seconds */
|
||||
long tv_usec; /* microseconds */
|
||||
};
|
||||
|
||||
struct timespec {
|
||||
time_t tv_sec; /* seconds */
|
||||
long tv_nsec; /* nanoseconds */
|
||||
};
|
||||
#endif
|
||||
|
||||
/** Timestamp */
|
||||
typedef struct timeval snd_timestamp_t;
|
||||
/** Hi-res timestamp */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue