diff options
author | kevlo <kevlo@FreeBSD.org> | 2008-09-02 02:59:38 +0000 |
---|---|---|
committer | kevlo <kevlo@FreeBSD.org> | 2008-09-02 02:59:38 +0000 |
commit | 3fe0cc5a82e4ca92f9ccaa2978f1b9cc6efc5351 (patch) | |
tree | 5bf24fb960e4802f7e5727ace6f280d15d63cc2a /usr.bin/locate | |
parent | 50b997c3ef37a1ddf001ca0d904e14d196e8ed03 (diff) | |
download | FreeBSD-src-3fe0cc5a82e4ca92f9ccaa2978f1b9cc6efc5351.zip FreeBSD-src-3fe0cc5a82e4ca92f9ccaa2978f1b9cc6efc5351.tar.gz |
Use RUSAGE_SELF for the current process instead of hardcoded value
Diffstat (limited to 'usr.bin/locate')
-rw-r--r-- | usr.bin/locate/locate/locate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/locate/locate/locate.c b/usr.bin/locate/locate/locate.c index 64ce7f9..d7529fb 100644 --- a/usr.bin/locate/locate/locate.c +++ b/usr.bin/locate/locate/locate.c @@ -325,7 +325,7 @@ cputime () { struct rusage rus; - getrusage(0, &rus); + getrusage(RUSAGE_SELF, &rus); return(rus.ru_utime.tv_sec * 1000 + rus.ru_utime.tv_usec / 1000); } #endif /* DEBUG */ |