added g_time1 function

This commit is contained in:
jsorg71 2005-12-10 02:26:26 +00:00
parent f5151bfc8d
commit c46c748148
2 changed files with 16 additions and 0 deletions

View File

@ -42,6 +42,7 @@
#include <signal.h>
#include <fcntl.h>
#include <pwd.h>
#include <time.h>
#endif
#include <stdlib.h>
@ -1000,3 +1001,16 @@ g_getuser_info(char* username, int* gid, int* uid, char* shell, char* dir,
#endif
return 0;
}
/*****************************************************************************/
/* returns the time since the Epoch (00:00:00 UTC, January 1, 1970),
measured in seconds. */
int
g_time1(void)
{
#if defined(_WIN32)
return 0;
#else
return time(0);
#endif
}

View File

@ -167,5 +167,7 @@ g_sigterm(int pid);
int
g_getuser_info(char* username, int* gid, int* uid, char* shell, char* dir,
char* gecos);
int
g_time1(void);
#endif