]> Sergey Matveev's repositories - nnn.git/commit
Fix #81: GUI programs shouldn't exit on closing the parent terminal
authorArun Prakash Jana <engineerarun@gmail.com>
Thu, 15 Mar 2018 22:54:29 +0000 (04:24 +0530)
committerArun Prakash Jana <engineerarun@gmail.com>
Thu, 15 Mar 2018 23:09:49 +0000 (04:39 +0530)
commit70c39a063d1097d33b8967b9a31618b5f826db72
treee53c322b094a6a73428941ecfa7d28c1a12ee277
parent9a359b06f0987e2a1d9b734119a04bf152acfea4
Fix #81: GUI programs shouldn't exit on closing the parent terminal

Issue reproduction steps:

1. Spawn a GUI program e.g. open a PDF file in zathura or evince.
2. Without quitting `nnn` close the terminal.
3. Notice that the application quits too.

Can be a nagging issue if someone is not using a drop-down terminal.

Fix: detach a GUI child and start it in a new session.

There are 2 aspects to this commit:

- It fixes #81: in cases where we do not wait for a spawned child we can assume
that the child is a GUI process. We detach and spawn the child in a new session.
- It changes the behaviour to @Rahi374's suggestion in PR #40 i.e. invoke the DE
opener in F_NOWAIT mode.
README.md
nnn.1
nnn.c