This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

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
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]