summaryrefslogtreecommitdiffstats
path: root/cpukit/score
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2002-08-07 15:03:52 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2002-08-07 15:03:52 +0000
commit41c4785ba67b93d22c78be9610a826816b46ff8b (patch)
tree5def5c4cf97d7c730bad9efbde0714c804fd2787 /cpukit/score
parent2002-08-07 Ralf Corsepius <corsepiu@faw.uni-ulm.de> (diff)
downloadrtems-41c4785ba67b93d22c78be9610a826816b46ff8b.tar.bz2
2002-08-07 Chris Johns <ccj@acm.org>
* src/coretodset.c: Correct calculation of ticks until next section boundary. It was incorrectly based upon current time not the time that is being set.
Diffstat (limited to 'cpukit/score')
-rw-r--r--cpukit/score/ChangeLog6
-rw-r--r--cpukit/score/src/coretodset.c4
2 files changed, 8 insertions, 2 deletions
diff --git a/cpukit/score/ChangeLog b/cpukit/score/ChangeLog
index 50c7be955c..60ac1bd870 100644
--- a/cpukit/score/ChangeLog
+++ b/cpukit/score/ChangeLog
@@ -1,3 +1,9 @@
+2002-08-07 Chris Johns <ccj@acm.org>
+
+ * src/coretodset.c: Correct calculation of ticks until next section
+ boundary. It was incorrectly based upon current time not the
+ time that is being set.
+
2002-07-31 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* src/Makefile.am: Build into libscore.a.
diff --git a/cpukit/score/src/coretodset.c b/cpukit/score/src/coretodset.c
index ddb6f8ee43..9480a6ead9 100644
--- a/cpukit/score/src/coretodset.c
+++ b/cpukit/score/src/coretodset.c
@@ -50,8 +50,8 @@ void _TOD_Set(
seconds_since_epoch - _TOD_Seconds_since_epoch );
ticks_until_next_second = _TOD_Ticks_per_second;
- if ( ticks_until_next_second > _TOD_Current.ticks )
- ticks_until_next_second -= _TOD_Current.ticks;
+ if ( ticks_until_next_second > the_tod->ticks )
+ ticks_until_next_second -= the_tod->ticks;
_TOD_Current = *the_tod;
_TOD_Seconds_since_epoch = seconds_since_epoch;