Browse Source

timespec_utils.hpp

getattr
Antonio SJ Musumeci 1 month ago
parent
commit
cb4bb9c9fd
  1. 17
      src/timespec_utils.hpp

17
src/timespec_utils.hpp

@ -2,6 +2,23 @@
namespace TimeSpec
{
static
inline
timespec
is_newer(const timespec &t0_,
const timespec &t1_)
{
if(t0_.tv_sec > t1_.tv_sec)
return t0_;
if(t0_.tv_sec == t1_.tv_sec)
{
if(t0_.tv_nsec > t1_.tv_nsec)
return t0_;
}
return t1_;
}
static
inline
timespec

Loading…
Cancel
Save