public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/97731] terminate called in std::experimental::filesystem::recursive_directory_iterator Date: Mon, 09 Nov 2020 15:27:56 +0000 [thread overview] Message-ID: <bug-97731-4-5InE0MKJcc@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-97731-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97731 --- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-8 branch has been updated by Jonathan Wakely <redi@gcc.gnu.org>: https://gcc.gnu.org/g:749cfa1f150d1e0749feb7aed8f68b8d0294b03f commit r8-10616-g749cfa1f150d1e0749feb7aed8f68b8d0294b03f Author: Jonathan Wakely <jwakely@redhat.com> Date: Thu Nov 5 17:26:13 2020 +0000 libstdc++: Use non-throwing increment in recursive_directory_iterator [PR 97731] As described in the PR, the recursive_directory_iterator constructor calls advance(ec), but ec is a pointer so it calls _Dir::advance(bool). The intention was to either call advance() or advance(*ec) depending whether the pointer is null or not. This fixes the bug and renames the parameter to ecptr to make similar mistakes less likely in future. libstdc++-v3/ChangeLog: PR libstdc++/97731 * src/filesystem/dir.cc (recursive_directory_iterator): Call the right overload of _Dir::advance. * testsuite/experimental/filesystem/iterators/97731.cc: New test. (cherry picked from commit 2f93a2a03a343a29f614a530d7657f1ed6347ed5)
next prev parent reply other threads:[~2020-11-09 15:27 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-11-05 13:51 [Bug libstdc++/97731] New: " torsten.hilbrich at secunet dot com 2020-11-05 14:10 ` [Bug libstdc++/97731] " redi at gcc dot gnu.org 2020-11-05 14:14 ` redi at gcc dot gnu.org 2020-11-05 18:01 ` cvs-commit at gcc dot gnu.org 2020-11-05 18:05 ` redi at gcc dot gnu.org 2020-11-09 14:53 ` cvs-commit at gcc dot gnu.org 2020-11-09 15:27 ` cvs-commit at gcc dot gnu.org [this message] 2020-11-09 15:29 ` redi at gcc dot gnu.org 2022-02-01 21:58 ` cvs-commit at gcc dot gnu.org 2023-10-04 11:29 ` cvs-commit at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-97731-4-5InE0MKJcc@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).