From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 2035A39960F3; Tue, 20 Apr 2021 18:52:51 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2035A39960F3 From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/99533] "operation not permitted" error on recursive_directory_iterator despite skip_permission_denied Date: Tue, 20 Apr 2021 18:52:51 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: 10.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Apr 2021 18:52:51 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D99533 --- Comment #8 from CVS Commits --- The releases/gcc-9 branch has been updated by Jonathan Wakely : https://gcc.gnu.org/g:b06bc096c4da89d8880f86fb0d9627168f22c50d commit r9-9375-gb06bc096c4da89d8880f86fb0d9627168f22c50d Author: Jonathan Wakely Date: Thu Mar 11 16:43:51 2021 +0000 libstdc++: Handle EPERM for filesystem access errors on MacOS [PR 99537] Contrary to what POSIX says, some directory operations on MacOS can fail with EPERM instead of EACCES, so we need to handle both. libstdc++-v3/ChangeLog: PR libstdc++/99533 * src/c++17/fs_dir.cc (recursive_directory_iterator): Use new helper function to check for permission denied errors. * src/filesystem/dir.cc (recursive_directory_iterator): Likewise. * src/filesystem/dir-common.h (is_permission_denied_error): New helper function. (cherry picked from commit 8cfb387388a90730ab36ac24d9049677db633a11)=