summaryrefslogtreecommitdiff
path: root/src/main.cc
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2016-10-06 23:35:32 +0100
committerMaxime Coste <frrrwww@gmail.com>2016-10-06 23:35:32 +0100
commit006be63a327ded416aa26f470af89e741d2cf651 (patch)
treed303429d98ab3b11eb020e2f295c12098126fb2e /src/main.cc
parent5dd47e9c33a390ce28afbfd7ab4ce0c2520a0d28 (diff)
Ensure local client is destroyed before we fork the server to background
The recent change that introduced defered client deletion made the local client destruction happens too late, putting the terminal in a bad state when we resumed the process as client only.
Diffstat (limited to 'src/main.cc')
-rw-r--r--src/main.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/main.cc b/src/main.cc
index 3faf79f7..d6fdb4e8 100644
--- a/src/main.cc
+++ b/src/main.cc
@@ -606,6 +606,7 @@ int run_server(StringView session, StringView init_command,
String selections = selection_list_to_string(local_client->context().selections());
ClientManager::instance().remove_client(*local_client, true);
+ client_manager.clear_client_trash();
convert_to_client_pending = false;
if (fork_server_to_background())