diff options
Diffstat (limited to 'lib-src/ntlib.c')
-rw-r--r-- | lib-src/ntlib.c | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/lib-src/ntlib.c b/lib-src/ntlib.c index 4b25796830e..2ac021936ae 100644 --- a/lib-src/ntlib.c +++ b/lib-src/ntlib.c @@ -34,6 +34,12 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ #include "ntlib.h" +char *sys_ctime (const time_t *); +FILE *sys_fopen (const char *, const char *); +int sys_chdir (const char *); +int mkostemp (char *, int); +int sys_rename (const char *, const char *); + /* MinGW64 defines _TIMEZONE_DEFINED and defines 'struct timespec' in its system headers. */ #ifndef _TIMEZONE_DEFINED @@ -44,6 +50,8 @@ struct timezone }; #endif +void gettimeofday (struct timeval *, struct timezone *); + #define MAXPATHLEN _MAX_PATH /* Emulate sleep...we could have done this with a define, but that @@ -90,7 +98,7 @@ getppid (void) getppid_parent = OpenProcess (SYNCHRONIZE, FALSE, atoi (ppid)); if (!getppid_parent) { - printf ("Failed to open handle to parent process: %d\n", + printf ("Failed to open handle to parent process: %lu\n", GetLastError ()); exit (1); } @@ -107,7 +115,7 @@ getppid (void) return 1; case WAIT_FAILED: default: - printf ("Checking parent status failed: %d\n", GetLastError ()); + printf ("Checking parent status failed: %lu\n", GetLastError ()); exit (1); } } @@ -250,16 +258,6 @@ fchown (int fd, unsigned uid, unsigned gid) return 0; } -/* Place a wrapper around the MSVC version of ctime. It returns NULL - on network directories, so we handle that case here. - (Ulrich Leodolter, 1/11/95). */ -char * -sys_ctime (const time_t *t) -{ - char *str = (char *) ctime (t); - return (str ? str : "Sun Jan 01 00:00:00 1970"); -} - FILE * sys_fopen (const char * path, const char * mode) { |