Change information
Commit message:
txtar: handle crlf line endings
Function isMarker detects a file marker line by checking if the data before
the first '\n' has a marker prefix and suffix.
In the case of CRLF line endings, the data before the first '\n' ends with
'\r', so the suffix check fails.
Here, '\r' is trimmed before checking the suffix.
Fixes golang/go#59264.
Change-Id: I030357915abaa61f492b9d3d81a7edbd5d09d78e
GitHub-Last-Rev: 69a9348f2fd1bca236d382ff5482d008dfa784b8
GitHub-Pull-Request: golang/tools#595
Files:
- M txtar/archive.go
- M txtar/archive_test.go
Change size: S
Delta: 2 files changed, 11 insertions(+), 0 deletions(-)
Branch: refs/heads/master
Submit Requirements:
Code-Review: +1 by Carlos Amedee, +2 by Michael Matloob, +2 by Sean Liao, +1 by Michael Matloob
TryBots-Pass: LUCI-TryBot-Result+1 by Go LUCI