]> granicus.if.org Git - zfs/commit
OpenZFS 8430 - dir_is_empty_readdir() doesn't properly handle error from fdopendir()
authorSowrabha Gopal <sowrabha.gopal@delphix.com>
Thu, 1 Jun 2017 20:27:02 +0000 (13:27 -0700)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Fri, 30 Jun 2017 18:11:01 +0000 (11:11 -0700)
commitaa6e82a6a55d6fde7a8dc1c21bf952df69ef9a20
tree4204240857983b457e4ff118d87d13cd95c0c343
parent1579dcbc9176d3875f3ce8926076e46a87d8e8ed
OpenZFS 8430 - dir_is_empty_readdir() doesn't properly handle error from fdopendir()

Authored by: Sowrabha Gopal <sowrabha.gopal@delphix.com>
Reviewed by: Serapheim Dimitropoulos <serapheim@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Dan Kimmel <dan.kimmel@delphix.com>
Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>
Reviewed by: Igor Kozhukhov <igor@dilos.org>
Approved by: Robert Mustacchi <rm@joyent.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: George Melikov <mail@gmelikov.ru>
Ported-by: Giuseppe Di Natale <dinatale2@llnl.gov>
dir_is_empty_readdir() immediately returns if fdopendir() fails.
We should close dirfd when that happens.

OpenZFS-issue: https://www.illumos.org/issues/8430
OpenZFS-commit: https://github.com/openzfs/openzfs/commit/e165e20
Closes #6289
lib/libzfs/libzfs_mount.c