libroot: check timeout interval parameter in ppoll(), pselect() and select()
* also introduce timeval_to_bigtime * time_private is c++ only Change-Id: I2bddbe5f95240735c7b42ccf429dcbb3f1e8bb1b Reviewed-on: https://review.haiku-os.org/c/haiku/+/5220 Tested-by: Commit checker robot <[email protected]> Reviewed-by: waddlesplash <[email protected]> Reviewed-by: Adrien Destugues <[email protected]>
This commit is contained in:
committed by
Adrien Destugues
parent
30294b6d05
commit
eb22dbd032
@@ -67,6 +67,14 @@ timeval_to_timespec(const timeval& val, timespec& spec)
|
||||
}
|
||||
|
||||
|
||||
static inline bool
|
||||
timeval_to_bigtime(const timeval& val, bigtime_t& _time)
|
||||
{
|
||||
timespec spec;
|
||||
return timeval_to_timespec(val, spec) && timespec_to_bigtime(spec, _time);
|
||||
}
|
||||
|
||||
|
||||
static inline void
|
||||
timespec_to_timeval(const timespec& spec, timeval& val)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user