forked from OSchip/llvm-project
Revert "Use possibly cached directory entry values when performing recursive directory iteration."
This reverts commit 04ce4aef00d3ee508327f6cf7bf1b1d200ab6238. llvm-svn: 337749
This commit is contained in:
parent
b00fb46479
commit
5a16f861e9
|
@ -359,13 +359,13 @@ bool recursive_directory_iterator::__try_recursion(error_code *ec) {
|
|||
bool skip_rec = false;
|
||||
error_code m_ec;
|
||||
if (!rec_sym) {
|
||||
file_status st(curr_it.__entry_.__get_sym_ft(&m_ec));
|
||||
file_status st = curr_it.__entry_.symlink_status(m_ec);
|
||||
if (m_ec && status_known(st))
|
||||
m_ec.clear();
|
||||
if (m_ec || is_symlink(st) || !is_directory(st))
|
||||
skip_rec = true;
|
||||
} else {
|
||||
file_status st(curr_it.__entry_.__get_ft(&m_ec));
|
||||
file_status st = curr_it.__entry_.status(m_ec);
|
||||
if (m_ec && status_known(st))
|
||||
m_ec.clear();
|
||||
if (m_ec || !is_directory(st))
|
||||
|
|
Loading…
Reference in New Issue