This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch master
in repository e16.

View the commit online.

commit 5aaa2857e64401ec18990930b730d022162ff160
Author: Kim Woelders <k...@woelders.dk>
AuthorDate: Sat Mar 30 09:23:24 2024 +0100

    session: Add some SM connection debug messages
---
 src/session.c | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/src/session.c b/src/session.c
index 1e308d7b..72004ec2 100644
--- a/src/session.c
+++ b/src/session.c
@@ -303,6 +303,9 @@ ice_io_error_handler(IceConn connection __UNUSED__)
 static void
 ice_exit(void)
 {
+    if (EDebug(EDBUG_TYPE_SESSION))
+        Eprintf("%s: smc=%p\n", __func__, sm_conn);
+
     SmcCloseConnection(sm_conn, 0, NULL);
     sm_conn = NULL;
     EventFdUnregister(sm_efd);
@@ -341,7 +344,7 @@ ice_init(void)
     int             sm_fd;
 
     if (!getenv("SESSION_MANAGER"))
-        return;
+        goto done;
 
     IceSetIOErrorHandler(ice_io_error_handler);
 
@@ -370,7 +373,7 @@ ice_init(void)
         Eprintf("While connecting to session manager: %s\n", error_string_ret);
 
     if (!sm_conn)
-        return;
+        goto done;
 
     style[0] = SmRestartIfRunning;
     style[1] = 0;
@@ -392,6 +395,10 @@ ice_init(void)
     fcntl(sm_fd, F_SETFD, fcntl(sm_fd, F_GETFD, 0) | FD_CLOEXEC);
 
     sm_efd = EventFdRegister(sm_fd, ice_msgs_process);
+
+  done:
+    if (EDebug(EDBUG_TYPE_SESSION))
+        Eprintf("%s: smc=%p\n", __func__, sm_conn);
 }
 
 #endif                          /* USE_SM */

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

Reply via email to