[dolphin] [Bug 431044] Terminal panel interrupts sourcing .bashrc at dolphin startup
Luigi Keith
bugzilla_noreply at kde.org
Fri Nov 19 22:52:46 GMT 2021
https://bugs.kde.org/show_bug.cgi?id=431044
--- Comment #3 from Luigi Keith <b25e1938fe at protonmail.com> ---
You can fix this without making changes to souce code by simply making your
.bashrc file as follows:
trap : SIGINT
## YOUR BASHRC CONTENT ##
trap - SIGINT
This redirects any interrup signals to null- command during the sourcing phase
and clears after sourcing has been done.
Why:
- Dolphin opens with the tabs opened in the last session.
- Dolphin parses all the paths of the tabs and starts calling directory changes
to the terminal.
- Dolphin has a failsafe feature when calling directory changes*[1]. It sends
SIGINT to terminal process before changing directory.
- This results in terminal (bash) interrupting .bashrc / .bash_profile parsing.
[1] panels/terminal/terminalpanel.cpp: TerminalPanel::sendCdToTerminal
// The TerminalV2 interface does not provide a way to delete the
// current line before sending a new input. This is mandatory,
// otherwise sending a 'cd x' to a existing 'rm -rf *' might
// result in data loss. As workaround SIGINT is sent.
const int processId = m_terminal->terminalProcessId();
if (processId > 0) {
kill(processId, SIGINT);
}
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the kfm-devel
mailing list