Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals   Examples  

test_get_utc_timestamp.c

This file shows how to use the function get_utc_timestamp ().

#include "date.h"
#include <stdlib.h>


extern struct tz_tab   tzs;


extern char *tzname[2];
extern time_t timezone;
extern int daylight;


int main (int argc, char *argv[])
{
   time_t res;

   res = get_utc_timestamp();
   if (res == (time_t)-1)
   {
     fprintf (stderr, "\nAn error occured while getting the current timestamp\n");
     return 1;
   }

   fprintf (stdout, "\nGTM (or UTC) timestamp : %lu", res);

   fprintf (stdout, "\n\n");
   return 0;
}

Generated on Thu Apr 3 16:23:40 2003 for Common_C_libraries by doxygen1.3-rc1