* [PATCH] fix lsns failure after zombie process
@ 2016-01-15 21:38 Yuriy M. Kaminskiy
2016-01-18 9:14 ` Karel Zak
0 siblings, 1 reply; 2+ messages in thread
From: Yuriy M. Kaminskiy @ 2016-01-15 21:38 UTC (permalink / raw)
To: util-linux
(At least on kernel 3.16), stat("/proc/${pid_of_zombie}/ns/mnt") returns
-ENOENT, as a result lsns stops scanning processes prematurely.
--- util-linux.orig/sys-utils/lsns.c
+++ util-linux/sys-utils/lsns.c
@@ -308,7 +308,7 @@ static int read_processes(struct lsns *l
while (proc_next_pid(proc, &pid) == 0) {
rc = read_process(ls, pid);
- if (rc && rc != -EACCES)
+ if (rc && rc != -EACCES && rc != -ENOENT)
break;
rc = 0;
}
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] fix lsns failure after zombie process
2016-01-15 21:38 [PATCH] fix lsns failure after zombie process Yuriy M. Kaminskiy
@ 2016-01-18 9:14 ` Karel Zak
0 siblings, 0 replies; 2+ messages in thread
From: Karel Zak @ 2016-01-18 9:14 UTC (permalink / raw)
To: Yuriy M. Kaminskiy; +Cc: util-linux
On Sat, Jan 16, 2016 at 12:38:00AM +0300, Yuriy M. Kaminskiy wrote:
> --- util-linux.orig/sys-utils/lsns.c
> +++ util-linux/sys-utils/lsns.c
> @@ -308,7 +308,7 @@ static int read_processes(struct lsns *l
Applied, thanks.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-01-18 9:14 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-15 21:38 [PATCH] fix lsns failure after zombie process Yuriy M. Kaminskiy
2016-01-18 9:14 ` Karel Zak
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox