summaryrefslogtreecommitdiffstats
path: root/win/cat.c
diff options
context:
space:
mode:
authornijtmans <nijtmans>2010-01-31 23:51:36 (GMT)
committernijtmans <nijtmans>2010-01-31 23:51:36 (GMT)
commit000ce914c4d1f4b493568ce10baa2341bc73b510 (patch)
tree012d77fe11409a3025fcb54cc6c78d69b36f953a /win/cat.c
parenta98a5188b672f397d17abf6e04182566e1d7a7bb (diff)
downloadtcl-000ce914c4d1f4b493568ce10baa2341bc73b510.zip
tcl-000ce914c4d1f4b493568ce10baa2341bc73b510.tar.gz
tcl-000ce914c4d1f4b493568ce10baa2341bc73b510.tar.bz2
Various CYGWIN-related fixes
backported from HEAD. Still configure script not modified, so CYGWIN build is still disabled. Reason: although the build succeeds with those changes, many tests still fail.
Diffstat (limited to 'win/cat.c')
-rw-r--r--win/cat.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/win/cat.c b/win/cat.c
index 91c38f4..4804466 100644
--- a/win/cat.c
+++ b/win/cat.c
@@ -8,11 +8,15 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: cat.c,v 1.3 2005/11/04 00:06:49 dkf Exp $
+ * RCS: @(#) $Id: cat.c,v 1.3.10.1 2010/01/31 23:51:37 nijtmans Exp $
*/
#include <stdio.h>
-#include <io.h>
+#ifdef __CYGWIN__
+# include <unistd.h>
+#else
+# include <io.h>
+#endif
#include <string.h>
int
@@ -20,7 +24,7 @@ main(void)
{
char buf[1024];
int n;
- char *err;
+ const char *err;
while (1) {
n = read(0, buf, sizeof(buf));