]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
pidfds: don't print a scary warning on ENOSYS
authorTycho Andersen <tycho@tycho.ws>
Tue, 23 Jul 2019 15:40:14 +0000 (09:40 -0600)
committerChristian Brauner <christian.brauner@ubuntu.com>
Sun, 11 Aug 2019 19:42:04 +0000 (21:42 +0200)
Most kernels don't have this functionality yet, and so the warning is
printed a lot. Our people are scared of warnings, so let's make it INFO
instead in this case.

Signed-off-by: Tycho Andersen <tycho@tycho.ws>
src/lxc/start.c

index c5bc8b15417887e09e5c76c171ff80320bde96a4..3c0461fbfbc8fb3db9e75f3c91588579ecfb6558 100644 (file)
@@ -1605,7 +1605,10 @@ static int proc_pidfd_open(pid_t pid)
 
        /* Test whether we can send signals. */
        if (lxc_raw_pidfd_send_signal(proc_pidfd, 0, NULL, 0)) {
-               SYSERROR("Failed to send signal through pidfd");
+               if (errno != ENOSYS)
+                       SYSERROR("Failed to send signal through pidfd");
+               else
+                       INFO("Sending signals through pidfds not supported on this kernel");
                return -1;
        }