Whamcloud - gitweb
e4crypt: remove unneeded stat(2) call in do_get_policy()
authorTheodore Ts'o <tytso@mit.edu>
Sun, 24 Jun 2018 23:28:13 +0000 (19:28 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 24 Jun 2018 23:28:13 +0000 (19:28 -0400)
commit10b6e089e589a3bfc2b1ee0c9aca98183e4b9b32
tree9c732f14bc5161bfe1ca7a78b0aa17bd0375811f
parent0790bf05a255d9cfdeaf0637e2a1a6072134b4a7
e4crypt: remove unneeded stat(2) call in do_get_policy()

We don't need to conditionally use O_DIRECTORY when opening a
directory.  Remove the unneeded stat, and a TOCTOU complaint from
Coverity.

Fixes-Coverity-Bug: 1293497
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
misc/e4crypt.c