GRASS Programmer's Manual  6.4.1(2011)
date.c
Go to the documentation of this file.
00001 
00017 #include <time.h>
00018 #include <grass/gis.h>
00019 
00020 
00030 char *G_date(void)
00031 {
00032     time_t clock;
00033     struct tm *local;
00034     char *date;
00035     char *d;
00036 
00037     time(&clock);
00038 
00039     local = localtime(&clock);
00040     date = asctime(local);
00041     for (d = date; *d; d++)
00042         if (*d == '\n')
00043             *d = 0;
00044 
00045     return date;
00046 }
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines