[Top][All Lists]

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

bug#52033: a bug in paste command

From: zsugabubus
Subject: bug#52033: a bug in paste command
Date: Mon, 22 Nov 2021 10:42:54 +0100


On Mon, Nov 22, 2021 at 05:23:33AM +0000, Visser, Gerard wrote:
>   Hard as it is for me to believe, it seems I have uncovered a bug in the 
> paste command. I got unexpected/incorrect results in the course of my work 
> (which I can describe as merging two data files from some electronic test 
> equipment for the purposes of analysis and plotting). Attached is a tarfile 
> of a test case with two files and a log showing the incorrect results and the 
> version info of paste.
>    I hope this email will reach the right people to investigate this.
>     If it is a known issue and there is a workaround for me to use, please do 
> let me know.

It is only your terminal emulator that tricks you: Your file contains
carriage returns that moves cursor to the first column, so that next
line will appear on top of the previous.

$ file e f
e: ASCII text, with CRLF line terminators
f: ASCII text, with CRLF line terminators

If you do `paste e f | cat -A`, you can see it yourself what's going on.
Use `tr -d '\r'` to remove unwanted CRs.


reply via email to

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