bug-gawk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug-gawk] Regression: CR characters are not stripped on Windows


From: Orgad Shaneh
Subject: [bug-gawk] Regression: CR characters are not stripped on Windows
Date: Mon, 26 Feb 2018 12:24:01 +0200

Hi,

CR characters used to be automatically stripped on Windows (MSYS2
environment). This is broken in 4.2.0.

Minimal example:
echo -en "foo\r\n\r\nbar\r\n" > foo.txt
awk '/^$/ { print "found" }' foo.txt # This worked with 4.1.4 and
doesn't work with 4.2.0
awk '/^\r$/ { print "found" }' foo.txt # This works with 4.2.0 and
doesn't work with 4.1.4

Bisected to commit 5db38f775d9ba239e125d81dff2010a2ddacb48e:
(* gawkmisc.c (cygwin_premain0, cygwin_premain2): Remove.
No longer needed).

Apparently it's still needed...

This issue was reported in https://github.com/git-for-windows/git/issues/1524

Proposed patch is attached.

- Orgad

Attachment: 0001-Revert-Update-posix-gawkmisc.c-remove-cygwin-code.patch
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]