Paste multiple line text sometimes corrupted in Cygwin bash shell #16725

Open
opened 2026-01-31 05:20:54 +00:00 by claunia · 5 comments
Owner

Originally created by @kery on GitHub (Feb 10, 2022).

Windows Terminal version

1.11.2921.0

Windows build number

10.0.19042.1466

Other Software

GNU bash, version 4.4.12(3)-release (x86_64-unknown-cygwin)

Steps to reproduce

Add a profile for Cygwin.

            {
                "commandline": "C:\\cygwin64\\bin\\bash.exe -l",
                "guid": "{09ff2493-xxxx-4ee9-xxxx-d7f90bb2xxxx}",
                "hidden": false,
                "icon": "C:\\cygwin64\\Cygwin-Terminal.ico",
                "name": "Cygwin"
            },

Open Cygwin bash shell in a Terminal tab window and execute vi /tmp/temp.txt and then paste multiple line text. For example:

this is a sample text to test Windows terminal copy-paste issue, line 1
this is a sample text to test Windows terminal copy-paste issue, line 2
this is a sample text to test Windows terminal copy-paste issue, line 3
this is a sample text to test Windows terminal copy-paste issue, line 4
this is a sample text to test Windows terminal copy-paste issue, line 5
this is a sample text to test Windows terminal copy-paste issue, line 6
this is a sample text to test Windows terminal copy-paste issue, line 7
this is a sample text to test Windows terminal copy-paste issue, line 8
this is a sample text to test Windows terminal copy-paste issue, line 9
this is a sample text to test Windows terminal copy-paste issue, line 10
this is a sample text to test Windows terminal copy-paste issue, line 11
this is a sample text to test Windows terminal copy-paste issue, line 12
this is a sample text to test Windows terminal copy-paste issue, line 13
this is a sample text to test Windows terminal copy-paste issue, line 14
this is a sample text to test Windows terminal copy-paste issue, line 15
this is a sample text to test Windows terminal copy-paste issue, line 16
this is a sample text to test Windows terminal copy-paste issue, line 17
this is a sample text to test Windows terminal copy-paste issue, line 18
this is a sample text to test Windows terminal copy-paste issue, line 19
this is a sample text to test Windows terminal copy-paste issue, line 20
this is a sample text to test Windows terminal copy-paste issue, line 21
this is a sample text to test Windows terminal copy-paste issue, line 22
this is a sample text to test Windows terminal copy-paste issue, line 23
this is a sample text to test Windows terminal copy-paste issue, line 24
this is a sample text to test Windows terminal copy-paste issue, line 25
this is a sample text to test Windows terminal copy-paste issue, line 26
this is a sample text to test Windows terminal copy-paste issue, line 27
this is a sample text to test Windows terminal copy-paste issue, line 28
this is a sample text to test Windows terminal copy-paste issue, line 29
this is a sample text to test Windows terminal copy-paste issue, line 30
this is a sample text to test Windows terminal copy-paste issue, line 31
this is a sample text to test Windows terminal copy-paste issue, line 32
this is a sample text to test Windows terminal copy-paste issue, line 33
this is a sample text to test Windows terminal copy-paste issue, line 34
this is a sample text to test Windows terminal copy-paste issue, line 35
this is a sample text to test Windows terminal copy-paste issue, line 36
this is a sample text to test Windows terminal copy-paste issue, line 37
this is a sample text to test Windows terminal copy-paste issue, line 38
this is a sample text to test Windows terminal copy-paste issue, line 39
this is a sample text to test Windows terminal copy-paste issue, line 40

Expected Behavior

The text pasted in Cygwin bash shell as is.

Actual Behavior

The text pasted in Cygwin bash shell corrupted sometimes. There is no such issue when using mintty.

https://user-images.githubusercontent.com/3469040/153351084-b25930f9-11c4-4886-9ce7-a889aa468207.mp4

Originally created by @kery on GitHub (Feb 10, 2022). ### Windows Terminal version 1.11.2921.0 ### Windows build number 10.0.19042.1466 ### Other Software GNU bash, version 4.4.12(3)-release (x86_64-unknown-cygwin) ### Steps to reproduce Add a profile for Cygwin. ``` { "commandline": "C:\\cygwin64\\bin\\bash.exe -l", "guid": "{09ff2493-xxxx-4ee9-xxxx-d7f90bb2xxxx}", "hidden": false, "icon": "C:\\cygwin64\\Cygwin-Terminal.ico", "name": "Cygwin" }, ``` Open Cygwin bash shell in a Terminal tab window and execute `vi /tmp/temp.txt` and then paste multiple line text. For example: ``` this is a sample text to test Windows terminal copy-paste issue, line 1 this is a sample text to test Windows terminal copy-paste issue, line 2 this is a sample text to test Windows terminal copy-paste issue, line 3 this is a sample text to test Windows terminal copy-paste issue, line 4 this is a sample text to test Windows terminal copy-paste issue, line 5 this is a sample text to test Windows terminal copy-paste issue, line 6 this is a sample text to test Windows terminal copy-paste issue, line 7 this is a sample text to test Windows terminal copy-paste issue, line 8 this is a sample text to test Windows terminal copy-paste issue, line 9 this is a sample text to test Windows terminal copy-paste issue, line 10 this is a sample text to test Windows terminal copy-paste issue, line 11 this is a sample text to test Windows terminal copy-paste issue, line 12 this is a sample text to test Windows terminal copy-paste issue, line 13 this is a sample text to test Windows terminal copy-paste issue, line 14 this is a sample text to test Windows terminal copy-paste issue, line 15 this is a sample text to test Windows terminal copy-paste issue, line 16 this is a sample text to test Windows terminal copy-paste issue, line 17 this is a sample text to test Windows terminal copy-paste issue, line 18 this is a sample text to test Windows terminal copy-paste issue, line 19 this is a sample text to test Windows terminal copy-paste issue, line 20 this is a sample text to test Windows terminal copy-paste issue, line 21 this is a sample text to test Windows terminal copy-paste issue, line 22 this is a sample text to test Windows terminal copy-paste issue, line 23 this is a sample text to test Windows terminal copy-paste issue, line 24 this is a sample text to test Windows terminal copy-paste issue, line 25 this is a sample text to test Windows terminal copy-paste issue, line 26 this is a sample text to test Windows terminal copy-paste issue, line 27 this is a sample text to test Windows terminal copy-paste issue, line 28 this is a sample text to test Windows terminal copy-paste issue, line 29 this is a sample text to test Windows terminal copy-paste issue, line 30 this is a sample text to test Windows terminal copy-paste issue, line 31 this is a sample text to test Windows terminal copy-paste issue, line 32 this is a sample text to test Windows terminal copy-paste issue, line 33 this is a sample text to test Windows terminal copy-paste issue, line 34 this is a sample text to test Windows terminal copy-paste issue, line 35 this is a sample text to test Windows terminal copy-paste issue, line 36 this is a sample text to test Windows terminal copy-paste issue, line 37 this is a sample text to test Windows terminal copy-paste issue, line 38 this is a sample text to test Windows terminal copy-paste issue, line 39 this is a sample text to test Windows terminal copy-paste issue, line 40 ``` ### Expected Behavior The text pasted in Cygwin bash shell as is. ### Actual Behavior The text pasted in Cygwin bash shell corrupted sometimes. There is no such issue when using mintty. https://user-images.githubusercontent.com/3469040/153351084-b25930f9-11c4-4886-9ce7-a889aa468207.mp4
claunia added the Issue-BugArea-InputProduct-TerminalPriority-2 labels 2026-01-31 05:20:54 +00:00
Author
Owner

@zadjii-msft commented on GitHub (Feb 10, 2022):

Weird. Does this repro with the vintage console host, conhost.exe by any chance?

@zadjii-msft commented on GitHub (Feb 10, 2022): Weird. Does this repro with the vintage console host, `conhost.exe` by any chance?
Author
Owner

@kery commented on GitHub (Feb 13, 2022):

Weird. Does this repro with the vintage console host, conhost.exe by any chance?

The same. The more number of lines the more possibility to reproduce this issue.

https://user-images.githubusercontent.com/3469040/153737691-c3195a77-b657-4576-8d4d-615e16d23c67.mp4

@kery commented on GitHub (Feb 13, 2022): > Weird. Does this repro with the vintage console host, `conhost.exe` by any chance? The same. The more number of lines the more possibility to reproduce this issue. https://user-images.githubusercontent.com/3469040/153737691-c3195a77-b657-4576-8d4d-615e16d23c67.mp4
Author
Owner

@kery commented on GitHub (Feb 18, 2022):

Please note that this issue cannot be reproduced by using ssh.exe in System32\OpenSSH\ with the conhost.exe. However, if using the same ssh.exe with bash.exe, it can be reproduced.

@kery commented on GitHub (Feb 18, 2022): Please note that this issue cannot be reproduced by using ssh.exe in System32\OpenSSH\ with the conhost.exe. However, if using the same ssh.exe with bash.exe, it can be reproduced.
Author
Owner

@sykwon66 commented on GitHub (May 6, 2022):

Also happens in 1.12.10982.0.
No issue with cmd and power shell.

@sykwon66 commented on GitHub (May 6, 2022): Also happens in 1.12.10982.0. No issue with cmd and power shell.
Author
Owner

@sykwon66 commented on GitHub (May 9, 2022):

Looks same issue with #6901

When Copying, Line Wrapped Text Is Inconsistently Broken Into Multiple Lines #6901

@sykwon66 commented on GitHub (May 9, 2022): Looks same issue with #6901 When Copying, Line Wrapped Text Is Inconsistently Broken Into Multiple Lines #6901
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#16725