Check for getrusage

Originally committed as revision 9627 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
Ramiro Polla
2007-07-13 16:04:00 +00:00
parent 0f69ca7f14
commit 66be5b4536
2 changed files with 5 additions and 0 deletions

View File

@@ -3113,10 +3113,12 @@ static int64_t getutime(void)
#else
static int64_t getutime(void)
{
#ifdef HAVE_GETRUSAGE
struct rusage rusage;
getrusage(RUSAGE_SELF, &rusage);
return (rusage.ru_utime.tv_sec * 1000000LL) + rusage.ru_utime.tv_usec;
#endif
}
#endif