Annotation of researchv10no/cmd/nupas/test.c, revision 1.1

1.1     ! root        1: #include <sys/types.h>
        !             2: #include <time.h>
        !             3: #include <stdio.h>
        !             4: 
        !             5: extern long time();
        !             6: extern void tzset();
        !             7: extern char *tzname[];
        !             8: 
        !             9: /*
        !            10:  *  return an ascii daytime string
        !            11:  */
        !            12: int
        !            13: main()
        !            14: {
        !            15:        static char date[32];
        !            16:        char *tp, *dp;
        !            17:        struct tm *bp;
        !            18:        long thetime;
        !            19: 
        !            20:        thetime = time((long *)0);
        !            21:        bp = localtime(&thetime);
        !            22:        dp = asctime(bp);
        !            23: 
        !            24:        printf("%.16s %d\n", dp, bp->tm_isdst);
        !            25:        return;
        !            26: }

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.