[BACK]Return to sleep.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / lib / libc / gen

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/lib/libc/gen/sleep.c between version 1.13 and 1.14

version 1.13, 1995/10/26 22:07:00 version 1.14, 1996/05/11 11:04:51
Line 104  sleep(seconds)
Line 104  sleep(seconds)
         ringring = 0;          ringring = 0;
         (void) sigsuspend(&set);          (void) sigsuspend(&set);
   
         if (ringring) {          if (!ringring) {
                 /* Our alarm went off; timer is not currently running */  
                 sigaction(SIGALRM, &oact, NULL);  
                 sigprocmask(SIG_SETMASK, &oset, NULL);  
                 (void) setitimer(ITIMER_REAL, &oitv, &itv);  
         } else {  
                 struct itimerval nulltv;                  struct itimerval nulltv;
                 /*                  /*
                  * Interrupted by other signal; allow for pending                   * Interrupted by other signal; allow for pending
Line 119  sleep(seconds)
Line 114  sleep(seconds)
                 timerclear(&nulltv.it_interval);                  timerclear(&nulltv.it_interval);
                 timerclear(&nulltv.it_value);                  timerclear(&nulltv.it_value);
                 (void) setitimer(ITIMER_REAL, &nulltv, &itv);                  (void) setitimer(ITIMER_REAL, &nulltv, &itv);
                 sigprocmask(SIG_SETMASK, &oset, NULL);  
                 sigaction(SIGALRM, &oact, NULL);  
                 (void) setitimer(ITIMER_REAL, &oitv, NULL);  
         }          }
           sigprocmask(SIG_SETMASK, &oset, NULL);
           sigaction(SIGALRM, &oact, NULL);
           (void) setitimer(ITIMER_REAL, &oitv, &itv);
   
         if (timerisset(&diff))          if (timerisset(&diff))
                 timeradd(&itv.it_value, &diff, &itv.it_value);                  timeradd(&itv.it_value, &diff, &itv.it_value);

Legend:
Removed from v.1.13  
changed lines
  Added in v.1.14

CVSweb <webmaster@jp.NetBSD.org>