From 8c1b852abf692af4898368132292eb8c7278a7c2 Mon Sep 17 00:00:00 2001 From: Oleksandr Shneyder Date: Tue, 10 Feb 2015 19:43:41 +0100 Subject: Save session state in file. 210_nxagent_save_session_state.full.patch 210_nxcomp_save_session_state.full+lite.patch This patch adds a "state" option to NX (agent) which allows one to specify a file where nxagent will write its session state into. --- nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'nx-X11/programs/Xserver/hw/nxagent/X') diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c index 69ad30d2d..f18c09fe4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c @@ -609,6 +609,7 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio #endif nxagentSessionState = SESSION_UP; + saveAgentState("RUNNING"); } #ifdef BLOCKS @@ -823,6 +824,7 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio */ fprintf(stderr, "Session: Terminating session at '%s'.\n", GetTimeAsString()); + saveAgentState("TERMINATING"); nxagentWaitDisplay(); @@ -833,6 +835,7 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio { NXShadowDestroy(); } + saveAgentState("TERMINATED"); KillAllClients(); DEALLOCATE_LOCAL(clientReady); -- cgit v1.2.3