Fix existing session daemon check
authorDavid Goulet <dgoulet@efficios.com>
Tue, 14 Feb 2012 20:33:20 +0000 (15:33 -0500)
committerDavid Goulet <dgoulet@efficios.com>
Tue, 14 Feb 2012 20:33:23 +0000 (15:33 -0500)
On unclean exit, the session daemon socket are not removed making the
access() test valid on the next session daemon execution and failing to
recover from a fatal error.

Signed-off-by: David Goulet <dgoulet@efficios.com>
src/bin/lttng-sessiond/main.c

index bf20850003ece493934432f876af883a59979f58..8e794bdf4365be1779c2f0bb94c5e99dae5b03ee 100644 (file)
@@ -3899,17 +3899,12 @@ end:
  */
 static int check_existing_daemon(void)
 {
-       if (access(client_unix_sock_path, F_OK) < 0 &&
-                       access(apps_unix_sock_path, F_OK) < 0) {
-               return 0;
-       }
-
        /* Is there anybody out there ? */
        if (lttng_session_daemon_alive()) {
                return -EEXIST;
-       } else {
-               return 0;
        }
+
+       return 0;
 }
 
 /*
This page took 0.028264 seconds and 4 git commands to generate.