Fix checking of foreground process

Review Request #128789 - Created Aug. 28, 2016 and submitted

Information
Martin Tobias Holmedahl Sandsmark
konsole
367746
Reviewers
konsole
hindenburg

The old method of checking it has unnecessary overhead (doing a full process info update), and wasn't very reliable.

Instead just get the original shell PID from QProcess (via KProcess), and the foreground process from the PTY.

It fixes https://bugs.kde.org/show_bug.cgi?id=367746 for me, also added debug output to print the shell PID and the current process PID to verify that it acted correctly when doing stuff.

Martin Tobias Holmedahl Sandsmark
Kurt Hindenburg
Martin Tobias Holmedahl Sandsmark
Review request changed

Status: Closed (submitted)

Change Summary:

Submitted with commit 17a3ee5dfa1fc99776a015b31e5862ce82ab1a56 by Kurt Hindenburg on behalf of Martin T. H. Sandsmark to branch Applications/16.08.
Loading...