diff options
author | Clark Williams <williams@redhat.com> | 2010-04-01 14:11:33 -0500 |
---|---|---|
committer | Clark Williams <williams@redhat.com> | 2010-04-01 14:11:33 -0500 |
commit | f37d47179d8e9ef2dad51b959676215d8cb83ad3 (patch) | |
tree | 69bfc0ab755549bb2ce132957017869044de9fec | |
parent | 5b346bd9e812e03b22c7a81212a84f7d6e20eee0 (diff) | |
download | rt-tests-f37d47179d8e9ef2dad51b959676215d8cb83ad3.tar.gz |
replace nanosleep with clock_nanosleep in pmqtest
Since it's doing relative time sleeps probably not an issue, but
move to clock_nanosleep(CLOCK_MONOTONIC, 0,...) to be clear.
Signed-off-by: Clark Williams <williams@redhat.com>
-rw-r--r-- | src/pmqtest/pmqtest.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pmqtest/pmqtest.c b/src/pmqtest/pmqtest.c index 6cd3d8a..2ac6c55 100644 --- a/src/pmqtest/pmqtest.c +++ b/src/pmqtest/pmqtest.c @@ -119,7 +119,7 @@ void *pmqthread(void *param) senddelay.tv_sec = par->forcetimeout; senddelay.tv_nsec = 0; - nanosleep(&senddelay, NULL); + clock_nanosleep(CLOCK_MONOTONIC, 0, &senddelay, NULL); } /* Send message: Start of latency measurement ... */ @@ -223,7 +223,7 @@ void *pmqthread(void *param) par->shutdown = 1; if (mustgetcpu) par->cpu = get_cpu(); - nanosleep(&par->delay, NULL); + clock_nanosleep(CLOCK_MONOTONIC, 0, &par->delay, NULL); /* Tell receiver that we are ready for the next measurement */ if (mq_send(par->syncmq, syncmsg, strlen(syncmsg), 1) != 0) { |