GNU bug report logs -
#18186
cat.c needs fixing since 1998
Previous Next
Reported by: "James Simmons" <james <at> pcug.us>
Date: Sun, 3 Aug 2014 20:19:02 UTC
Severity: normal
Tags: moreinfo
Done: Assaf Gordon <assafgordon <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Paul Eggert wrote:
> James Simmons, President & CEO wrote:
>> cat file1.txt file2.txt >>output.txt
>>
>> file1.txt contains a single line containing IP addresses.
>> file2.txt contains a single line with more IP addresses.
>>
>> output.txt SHOULD contain a single line
>
> If the input contains two lines, the output should too. Sorry, I
> don't see a bug here.
---
If he is using an editor like Vim,
it will not show you the last linefeeds in the file because
it always inserts them automatically unless you are in binary mode.
I had a similar problem with vim force inserting an LF on a file update,
just to "help me". The problem comes when you want to concatenate
text fields, where neither are terminated by an LF. I think that may be
what the OP is expecting, not knowing that the problem may be in their text
editor that won't inhibit LF <at> EOF in text mode even though it has a flag
for it.
This bug report was last modified 6 years and 274 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.