public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "jb.1234abcd at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/57111] Core dump - invalid pointer detected after std::unique_ptr Date: Tue, 30 Apr 2013 22:22:00 -0000 [thread overview] Message-ID: <bug-57111-4-iGqFvC5Q2Q@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-57111-4@http.gcc.gnu.org/bugzilla/> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57111 --- Comment #7 from jb <jb.1234abcd at gmail dot com> 2013-04-30 22:22:44 UTC --- (In reply to comment #6) > (In reply to comment #5) > > It seems to me that the option "free-nonheap-object" does not work in gcc. > > You need to add -O2 (maybe -O1 is enough, sometimes you need -O3), otherwise > gcc does not propagate the information of what p is all the way to free. OK, that worked. $ gcc -O1 -Wall -o free-test free-test.c free-test.c: In function ‘main’: free-test.c:6:7: warning: attempt to free a non-heap object ‘arr’ [-Wfree-nonheap-object] >From gcc-bugs-return-421323-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Apr 30 22:50:16 2013 Return-Path: <gcc-bugs-return-421323-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org> Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 29022 invoked by alias); 30 Apr 2013 22:50:16 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: <gcc-bugs.gcc.gnu.org> List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/> List-Post: <mailto:gcc-bugs@gcc.gnu.org> List-Help: <mailto:gcc-bugs-help@gcc.gnu.org> Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 28997 invoked by uid 48); 30 Apr 2013 22:50:13 -0000 From: "jb.1234abcd at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/57111] Core dump - invalid pointer detected after std::unique_ptr Date: Tue, 30 Apr 2013 22:50:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jb.1234abcd at gmail dot com X-Bugzilla-Status: VERIFIED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Status Message-ID: <bug-57111-4-DuX2JA4WZq@http.gcc.gnu.org/bugzilla/> In-Reply-To: <bug-57111-4@http.gcc.gnu.org/bugzilla/> References: <bug-57111-4@http.gcc.gnu.org/bugzilla/> X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 X-SW-Source: 2013-04/txt/msg02468.txt.bz2 Content-length: 474 http://gcc.gnu.org/bugzilla/show_bug.cgi?idW111 jb <jb.1234abcd at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |VERIFIED --- Comment #8 from jb <jb.1234abcd at gmail dot com> 2013-04-30 22:50:12 UTC --- Please reopen this bug report. The RFE will make this feature consistent across gcc and g++.
next prev parent reply other threads:[~2013-04-30 22:22 UTC|newest] Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top 2013-04-29 12:29 [Bug c++/57111] New: " jb.1234abcd at gmail dot com 2013-04-29 12:57 ` [Bug c++/57111] " redi at gcc dot gnu.org 2013-04-29 14:04 ` jb.1234abcd at gmail dot com 2013-04-29 14:09 ` redi at gcc dot gnu.org 2013-04-30 18:37 ` glisse at gcc dot gnu.org 2013-04-30 21:57 ` jb.1234abcd at gmail dot com 2013-04-30 22:07 ` glisse at gcc dot gnu.org 2013-04-30 22:22 ` jb.1234abcd at gmail dot com [this message] 2013-04-30 22:58 ` [Bug c++/57111] Generalize -Wfree-nonheap-object to delete glisse at gcc dot gnu.org 2013-04-30 23:01 ` redi at gcc dot gnu.org 2020-11-05 17:52 ` msebor at gcc dot gnu.org 2020-11-09 14:51 ` redi at gcc dot gnu.org 2020-12-03 22:56 ` msebor at gcc dot gnu.org 2020-12-08 20:51 ` msebor at gcc dot gnu.org 2020-12-14 20:31 ` cvs-commit at gcc dot gnu.org 2020-12-14 20:34 ` msebor at gcc dot gnu.org 2021-01-10 23:21 ` cvs-commit at gcc dot gnu.org 2023-06-14 9:43 ` cvs-commit at gcc dot gnu.org 2023-06-15 7:21 ` 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-57111-4-iGqFvC5Q2Q@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).