To set/check/clear a project quota, xfs_quota performs a pre-order tree
traversal by using nftw(3). The documentation states that the -d option
can be used to skip subtrees below a certain level in the directory
hierarchy. Unfortunately, {check,setup,clear}_project returns -1 when
DEPTH is hit, which stops the directory tree walk immediately. We only
wanted to skip the subtree, so return 0 instead.
Signed-off-by: Kazuya Mio <k-mio@sx.jp.nec.com>
Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
int fd;
if (recurse_depth >= 0 && data->level > recurse_depth)
- return -1;
+ return 0;
if (flag == FTW_NS ){
exitcode = 1;
int fd;
if (recurse_depth >= 0 && data->level > recurse_depth)
- return -1;
+ return 0;
if (flag == FTW_NS ){
exitcode = 1;
int fd;
if (recurse_depth >= 0 && data->level > recurse_depth)
- return -1;
+ return 0;
if (flag == FTW_NS ){
exitcode = 1;