]> Cypherpunks repositories - gostls13.git/commitdiff
include: remove unnecessary stuff on windows
authorShenghou Ma <minux@golang.org>
Thu, 1 Jan 2015 07:23:55 +0000 (02:23 -0500)
committerMinux Ma <minux@golang.org>
Fri, 2 Jan 2015 03:36:11 +0000 (03:36 +0000)
Our definition of struct timespec used to cause problems with
certain versions of mingw-rt. However, as it turns out, we don't
actually need those definitions and prototypes, so remove them.

Fixes #9472.

Change-Id: Ie0880f0d58be112625140f73d0bed71f98b7cf05
Reviewed-on: https://go-review.googlesource.com/2236
Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
include/libc.h

index e10dde3adf9c4703ba6b46c62677971b15afd9e5..e4d879907720ad3a874ff6c38eef77346069399d 100644 (file)
@@ -310,24 +310,15 @@ extern    void    flagprint(int);
 #ifdef _WIN32
 
 #if !defined(_WIN64) && !defined(__MINGW64_VERSION_MAJOR)
-struct timespec {
-       int tv_sec;
-       long tv_nsec;
-};
 #define execv(prog, argv) execv(prog, (const char* const*)(argv))
 #define execvp(prog, argv) execvp(prog, (const char**)(argv))
 #endif
 
-extern int nanosleep(const struct timespec *rqtp, struct timespec *rmtp);
-extern int fork(void);
-extern int pread(int fd, void *buf, int n, int off);
-extern int pwrite(int fd, void *buf, int n, int off);
 #undef  getwd
 #define getwd(s, ns) getcwd(s, ns)
 #undef  lseek
 #define lseek(fd, n, base) _lseeki64(fd, n, base)
 #define mkdir(path, perm) mkdir(path)
-#define pipe(fd) _pipe(fd, 512, O_BINARY)
 #else
 #define O_BINARY 0
 #endif