]> git.ipfire.org Git - thirdparty/util-linux.git/commit
lib/procutils: improve proc_is_procfs(), add test
authorKarel Zak <kzak@redhat.com>
Fri, 20 Nov 2020 09:38:01 +0000 (10:38 +0100)
committerKarel Zak <kzak@redhat.com>
Fri, 20 Nov 2020 09:40:31 +0000 (10:40 +0100)
commit1b54a74e8622d18b3be53ca440928d96e73bac3d
tree0c50964e20a16136710c31d92427a6736163d6a2
parent61dc5ae39a3c72c01212e7d58b16a1321fc55e04
lib/procutils: improve proc_is_procfs(), add test

* add delay between attempts
* zeroize errno and check for EAGAIN (like in other code)
* add small test program
   ./test_procutils --is-procfs [<dir>]

Signed-off-by: Karel Zak <kzak@redhat.com>
lib/procutils.c