Bug 504228 - Pasting selection from a hung terminal causes Konsole to freeze.
Summary: Pasting selection from a hung terminal causes Konsole to freeze.
Status: RESOLVED UNMAINTAINED
Alias: None
Product: konsole
Classification: Applications
Component: copy-paste (other bugs)
Version First Reported In: 22.12.3
Platform: Debian stable Linux
: NOR crash
Target Milestone: ---
Assignee: Konsole Developer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-05-14 17:59 UTC by Samuel Plavec
Modified: 2025-05-16 20:41 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Samuel Plavec 2025-05-14 17:59:19 UTC
SUMMARY
Pasting selection using middle-click from a hung terminal causes Konsole to freeze; see the below steps for more details. 

STEPS TO REPRODUCE
1. In the settings of the current profile, in the "Mouse" section, set the setting "Middle-click pastes:" to "From selection".
2. Open two Konsoles. I will call them "Konsole #1" and "Konsole #2".
3. In Konsole #2, type "konsole" and press enter. This will open Konsole #3.
4. Select some text in Konsole #3.
5. In Konsole #2, press ^Z. This will suspend Konsole #3.
6. In Konsole #1, press the middle button.

OBSERVED RESULT
Konsole #1 now freezes until Konsole #3 is resumed or terminated.

EXPECTED RESULT
Konsole #1 should not freeze. A possible solution would be that after a timeout, Konsole #1 should stop waiting for the frozen Konsole to send the selected text, and possibly send a notification to the user that the paste was unsuccessful.

SOFTWARE/OS VERSIONS
Linux: Debian 12 (Kernel: 6.1.0-34-amd64 (64-bit))
KDE Plasma Version: 5.27.5
KDE Frameworks Version: 5.103.0
Qt Version: 5.15.8
Graphics Platform: X11

ADDITIONAL INFORMATION
It may be non-evident the the middle-click caused the freeze of Konsole #1, so the user may not know how to revive it, possibly losing their work.

This bug is quite unlikely to be trigerred, so its severity may need to be lowered (to "Minor", even), but it nonetheless fits "Crash" the best.

In the analogous situation, xterm doesn't wait for the frozen terminal to send to copied text, but instead pastes it as soon as the frozen terminal unfreezes, without regard to any text that could have been typed in the meantime. This causes the typed text to precede the pasted text, even though the latter should have been first. This behavior seems to be related to the Debian bug 2297 (https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=2297), and is mentioned in the very last non-spam reply.
Comment 1 Samuel Plavec 2025-05-14 18:08:54 UTC
(In reply to Samuel Plavec from comment #0)
> 3. In Konsole #2, type "konsole" and press enter. This will open Konsole #3.
I have found out that "Konsole #3" can actually be any program, for example Kate, for this steps to cause the reported behavior.
Comment 2 John Kizer 2025-05-16 19:11:43 UTC
Thank you for your bug report!

Debian advises users to not submit bugs upstream (https://www.debian.org/Bugs/Reporting), as this version of the KDE software is out of support from KDE, and so it's possible that the bug exists only in Debian at this point.

Could you report the bug to Debian using the report bug utility (https://packages.debian.org/stable/utils/reportbug)? If necessary, the maintainer of the package will forward the bug upstream.

Thanks for understanding!
Comment 3 Samuel Plavec 2025-05-16 20:41:26 UTC
(In reply to John Kizer from comment #2)
> Thank you for your bug report!
> 
> Debian advises users to not submit bugs upstream
> (https://www.debian.org/Bugs/Reporting), as this version of the KDE software
> is out of support from KDE, and so it's possible that the bug exists only in
> Debian at this point.
> 
> Could you report the bug to Debian using the report bug utility
> (https://packages.debian.org/stable/utils/reportbug)? If necessary, the
> maintainer of the package will forward the bug upstream.
> 
> Thanks for understanding!

I will report this bug to Debian. Thank you for the clarification.