Home | History | Annotate | Line # | Download | only in c
      1  1.1  christos /* CB_SYS_time doesn't implement the Linux time syscall; the return
      2  1.1  christos    value isn't written to the argument.  */
      3  1.1  christos 
      4  1.1  christos #include <time.h>
      5  1.1  christos #include <stdio.h>
      6  1.1  christos #include <stdlib.h>
      7  1.1  christos 
      8  1.1  christos int
      9  1.1  christos main (void)
     10  1.1  christos {
     11  1.1  christos   time_t x = (time_t) -1;
     12  1.1  christos   time_t t = time (&x);
     13  1.1  christos 
     14  1.1  christos   if (t == (time_t) -1 || t != x)
     15  1.1  christos     abort ();
     16  1.1  christos   printf ("pass\n");
     17  1.1  christos   exit (0);
     18  1.1  christos }
     19