summaryrefslogtreecommitdiffstats
path: root/cpukit/posix/src/clockgettime.c
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2015-05-29 15:03:02 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2015-05-29 15:03:46 +0200
commit8f6a31459c8e57db79f14f8a80777136e006a1d3 (patch)
tree045ab774fe9409f8b2998482a84acbf6535a7285 /cpukit/posix/src/clockgettime.c
parentbsps/powerpc: Fix potential integer overflow (diff)
downloadrtems-8f6a31459c8e57db79f14f8a80777136e006a1d3.tar.bz2
posix: Fix clock_gettime()
The _TOD_Get_zero_based_uptime_as_timespec() returns already the right value.
Diffstat (limited to 'cpukit/posix/src/clockgettime.c')
-rw-r--r--cpukit/posix/src/clockgettime.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/cpukit/posix/src/clockgettime.c b/cpukit/posix/src/clockgettime.c
index 83a35d769a..b3adbc4713 100644
--- a/cpukit/posix/src/clockgettime.c
+++ b/cpukit/posix/src/clockgettime.c
@@ -43,7 +43,6 @@ int clock_gettime(
#ifdef CLOCK_MONOTONIC
if ( clock_id == CLOCK_MONOTONIC ) {
_TOD_Get_zero_based_uptime_as_timespec( tp );
- --tp->tv_sec;
return 0;
}
#endif
@@ -51,7 +50,6 @@ int clock_gettime(
#ifdef _POSIX_CPUTIME
if ( clock_id == CLOCK_PROCESS_CPUTIME_ID ) {
_TOD_Get_zero_based_uptime_as_timespec( tp );
- --tp->tv_sec;
return 0;
}
#endif