projects
/
ostree.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5daae86
)
rofiles-fuse: Add missing error handling for fcntl()
author
Colin Walters
<walters@verbum.org>
Mon, 31 Jul 2017 13:34:33 +0000
(09:34 -0400)
committer
Atomic Bot
<atomic-devel@projectatomic.io>
Wed, 2 Aug 2017 15:34:16 +0000
(15:34 +0000)
Spotted by Coverity.
Coverity CID:
1452201
Closes: #1037
Approved by: jlebon
src/rofiles-fuse/main.c
patch
|
blob
|
history
diff --git
a/src/rofiles-fuse/main.c
b/src/rofiles-fuse/main.c
index 12a9d886318679e7a49236f614764362d4ededd0..88cdba6cde0ae71e5b1b36fd126c2773e4e77951 100644
(file)
--- a/
src/rofiles-fuse/main.c
+++ b/
src/rofiles-fuse/main.c
@@
-96,6
+96,8
@@
callback_readdir (const char *path, void *buf, fuse_fill_dir_t filler,
if (!*path)
{
dfd = fcntl (basefd, F_DUPFD_CLOEXEC, 3);
+ if (dfd < 0)
+ return -errno;
lseek (dfd, 0, SEEK_SET);
}
else