diff -urN delta-2006.08.03.orig/topformflat.c delta-2006.08.03/topformflat.c
--- delta-2006.08.03.orig/topformflat.c	2015-01-19 14:17:12.480653300 +0000
+++ delta-2006.08.03/topformflat.c	2015-01-19 14:28:25.664636800 +0000
@@ -1820,6 +1820,11 @@
     threshold = atoi(argv[1]);    // user-specified threshold
   }  
 
+/* Re-open stdin in text mode to prevent CRLF from causing failures */
+#if defined(__CYGWIN__) || defined(__MSYS__) || defined(_WIN32)
+  freopen(NULL, "rt", stdin);
+#endif
+
   yyin = stdin;
   yylex();
   return 0;
