diff options
| author | jsorg71 <jsorg71> | 2005-12-10 02:26:26 +0000 | 
|---|---|---|
| committer | jsorg71 <jsorg71> | 2005-12-10 02:26:26 +0000 | 
| commit | c46c748148bb8e1d6b48bb2740adf6b2d1a11b1b (patch) | |
| tree | fbfdf72a7226279c8613d4763bdfff13ebcb8c0c | |
| parent | f5151bfc8d63a6d71c68460a03138164f376886d (diff) | |
| download | xrdp-proprietary-c46c748148bb8e1d6b48bb2740adf6b2d1a11b1b.tar.gz xrdp-proprietary-c46c748148bb8e1d6b48bb2740adf6b2d1a11b1b.zip | |
added g_time1 function
| -rw-r--r-- | common/os_calls.c | 14 | ||||
| -rw-r--r-- | common/os_calls.h | 2 | 
2 files changed, 16 insertions, 0 deletions
| diff --git a/common/os_calls.c b/common/os_calls.c index 45b60bd7..088424ec 100644 --- a/common/os_calls.c +++ b/common/os_calls.c @@ -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 +} diff --git a/common/os_calls.h b/common/os_calls.h index cf26cf20..a2659401 100644 --- a/common/os_calls.h +++ b/common/os_calls.h @@ -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 | 
