This is the mail archive of the
mailing list for the Cygwin project.
Changed line terminator behavior for grep
- From: "Tischler, Ron" <ron dot tischler at hp dot com>
- To: "cygwin at cygwin dot com" <cygwin at cygwin dot com>
- Date: Tue, 3 Aug 2010 01:19:25 +0000
- Subject: Changed line terminator behavior for grep
It appears that grep's line termination behavior has changed.
Version 2.5.4-2 of grep ends lines with carriage return and linefeed.
Version 2.6.3-1 of grep only puts a linefeed.
I'm curious to know if this is a bug that will be fixed, or if this is the desired new behavior.
I'm running both of them in the same place (a Vista machine).
If that doesn't sound right, here are more details. I had previously installed Cygwin 1.6 last year. Today, I wanted to get something else from Cygwin, so that automatically updated things to Cygwin 1.7.5. Then, test cases that compared output files against previous reference files stopped working. The difference was that the old ones had a carriage return and line feed on each line, and the new ones only had a linefeed. I noticed that this only affected tests where the output files were created by grep. Sure enough, I went back to Cygwin, and saw that there were two choices for grep (as shown above). I reinstalled the older version of grep from Cygwin and the tests started working again. I believe this shows that it is a difference in the behaviors of the two versions of grep, when either one is simply installed from Cygwin without doing anything tricky.
I don't know if this has been reported before. I tried to figure out how to search the Cygwin archives, but didn't succeed.
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple