summaryrefslogtreecommitdiff
path: root/src/fold.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1993-11-02 22:10:58 +0000
committerJim Meyering <jim@meyering.net>1993-11-02 22:10:58 +0000
commit56deeee42bbd4d1b0070ce77bb87d5f0116a3ee2 (patch)
tree373a9439c3f993b45ea812da1e3e9955e98d285a /src/fold.c
parent693e5c427acae56adc00427ad15250373729fc1d (diff)
downloadcoreutils-56deeee42bbd4d1b0070ce77bb87d5f0116a3ee2.tar.xz
merge with 1.8.1b
Diffstat (limited to 'src/fold.c')
-rw-r--r--src/fold.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/fold.c b/src/fold.c
index 9f9f0c8c5..eda7e039f 100644
--- a/src/fold.c
+++ b/src/fold.c
@@ -254,6 +254,14 @@ fold_file (filename, width)
goto rescan;
}
}
+ else
+ {
+ if (offset_out == 0)
+ {
+ line_out[offset_out++] = c;
+ continue;
+ }
+ }
line_out[offset_out++] = '\n';
fwrite (line_out, sizeof (char), offset_out, stdout);
column = offset_out = 0;