/* unexpand - convert spaces to tabs
- Copyright (C) 89, 91, 95, 96, 1997, 1998 Free Software Foundation, Inc.
+ Copyright (C) 89, 91, 1995-1998, 1999 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
if (fp == NULL)
return;
+ /* Binary I/O will preserve the original EOL style (DOS/Unix) of files. */
+ SET_BINARY2 (fileno (fp), STDOUT_FILENO);
+
for (;;)
{
c = getc (fp);
if (fp == NULL)
break; /* No more files. */
else
- continue;
+ {
+ SET_BINARY2 (fileno (fp), STDOUT_FILENO);
+ continue;
+ }
}
if (convert)