You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Mladen Turk <mt...@apache.org> on 2008/10/21 08:51:55 UTC

Re: svn commit: r706458 - /apr/apr/trunk/include/apr_time.h

wrowe@apache.org wrote:
> URL: http://svn.apache.org/viewvc?rev=706458&view=rev
> Log:
> A new macro for apr 1.4/2.0, for msec resolution - apr_time_from_sec(x*1000) is clumsy
>

That's cool!

What do you think of adding some apr_time_diff_* macros.
For example:

#define apr_time_diff_sec(t1, t2)  (apr_time_sec(t1) - apr_time_sec(t2))
#define apr_time_diff_msec(t1, t2) (apr_time_from_msec(t1) - 
apr_time_from_msec(t2))

Those would give only full sec or msec difference without
real resolution fraction.

Regards
-- 
^(TM)