GRASS Programmer's Manual  6.5.svn(2014)-r66266
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
date.c
Go to the documentation of this file.
1 
17 #include <time.h>
18 #include <grass/gis.h>
19 
20 
30 char *G_date(void)
31 {
32  time_t clock;
33  struct tm *local;
34  char *date;
35  char *d;
36 
37  time(&clock);
38 
39  local = localtime(&clock);
40  date = asctime(local);
41  for (d = date; *d; d++)
42  if (*d == '\n')
43  *d = 0;
44 
45  return date;
46 }
struct tm * localtime()
char * G_date(void)
Current date and time.
Definition: date.c:30