]> git.ipfire.org Git - thirdparty/util-linux.git/commit
blkdiscard: use fstat() rather than stat() [coverity scan]
authorKarel Zak <kzak@redhat.com>
Tue, 6 Aug 2013 08:29:04 +0000 (10:29 +0200)
committerKarel Zak <kzak@redhat.com>
Tue, 6 Aug 2013 08:29:04 +0000 (10:29 +0200)
commit777519226d033fdea9bcad043c01aa6539c8b71d
tree2fb7de949759a93629c1a8e109efd29de306918f
parent21ce3f3a4ec1a7cf97379aa4157cecc657cb814e
blkdiscard: use fstat() rather than stat() [coverity scan]

 Calling function "open(char const *, int, ...)" that uses "path" after
 a check function. This can cause a time-of-check, time-of-use race
 condition.

.. well, in blkdiscard context it's mostly cosmetic change.

Signed-off-by: Karel Zak <kzak@redhat.com>
sys-utils/blkdiscard.c