blocking pre-emting
Senthil Nathan V <[email protected]> Thu, 18 Dec 2003 11:33:30 +0530
| Newsgroups | gmane.comp.lib.phil |
|---|---|
| Organization | Odyssey Technologies |
| Message-ID | <[email protected]> |
Hell Everyone!! I have this situation. I need to take the current time of the system, and update with the new value and set the time. I'm doing some thing like this 1. t = gettime() ; 2. t = t + deviation ; 3. settime( t ) ; I assume that time taken to execute these statements is negligible. My doubt is if there is no switch over at the time of execution of these statements the time would be set almost right but, if any switch over occurs before statement 3 and after statement 1. I might miss some seconds in the actual time. 1. How do I over come this? 2. Is there any way I to block pre-emtion at the time of execution of these sequence of statements in user program? Thanks in advance.. --regards, Senthil Nathan V Odyssey Technologies Limited