public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/30368] missing warning for dereferencing null pointer
[not found] <bug-30368-4@http.gcc.gnu.org/bugzilla/>
@ 2013-11-19 6:29 ` law at redhat dot com
2020-05-19 0:09 ` msebor at gcc dot gnu.org
2021-12-18 11:24 ` egallager at gcc dot gnu.org
2 siblings, 0 replies; 5+ messages in thread
From: law at redhat dot com @ 2013-11-19 6:29 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30368
Jeffrey A. Law <law at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |NEW
CC| |law at redhat dot com
Resolution|DUPLICATE |---
--- Comment #8 from Jeffrey A. Law <law at redhat dot com> ---
The plan for 16351 would be to catch in gimple-ssa-isolate-paths.c, but that
won't catch this instance because of the wrapping ADDR_EXPR.
Regardless, while related, this is not, IMHO a dup of 16351
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/30368] missing warning for dereferencing null pointer
[not found] <bug-30368-4@http.gcc.gnu.org/bugzilla/>
2013-11-19 6:29 ` [Bug c/30368] missing warning for dereferencing null pointer law at redhat dot com
@ 2020-05-19 0:09 ` msebor at gcc dot gnu.org
2021-12-18 11:24 ` egallager at gcc dot gnu.org
2 siblings, 0 replies; 5+ messages in thread
From: msebor at gcc dot gnu.org @ 2020-05-19 0:09 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=30368
Martin Sebor <msebor at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |diagnostic
CC| |msebor at gcc dot gnu.org
Last reconfirmed|2007-03-13 16:12:46 |2020-5-18
--- Comment #9 from Martin Sebor <msebor at gcc dot gnu.org> ---
Missing warning reconfirmed with GCC 11.
The last pass where the null pointer is still available is the CCP1 pass whose
output shows that it removes it:
$ gcc -O2 -S -Wall -Wextra -fdump-tree-ccp1-all=/dev/stdout pr30368.c
...
Substituting values and folding statements
Folding statement: _1 = &a_3->b;
Folded into: _1 = 0B;
Folding statement: if (_1 != 0B)
...
So it should be possible to diagnose the dereference there, just prior to its
removal.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/30368] missing warning for dereferencing null pointer
[not found] <bug-30368-4@http.gcc.gnu.org/bugzilla/>
2013-11-19 6:29 ` [Bug c/30368] missing warning for dereferencing null pointer law at redhat dot com
2020-05-19 0:09 ` msebor at gcc dot gnu.org
@ 2021-12-18 11:24 ` egallager at gcc dot gnu.org
2 siblings, 0 replies; 5+ messages in thread
From: egallager at gcc dot gnu.org @ 2021-12-18 11:24 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=30368
Eric Gallager <egallager at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
See Also| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=16351
--- Comment #10 from Eric Gallager <egallager at gcc dot gnu.org> ---
(In reply to Jeffrey A. Law from comment #8)
> The plan for 16351 would be to catch in gimple-ssa-isolate-paths.c, but that
> won't catch this instance because of the wrapping ADDR_EXPR.
>
> Regardless, while related, this is not, IMHO a dup of 16351
putting it under "See Also" then
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/30368] missing warning for dereferencing null pointer
2007-01-04 14:21 [Bug c/30368] New: wrong result lidaobing at gmail dot com
2007-03-13 16:13 ` [Bug c/30368] missing warning for dereferencing null pointer manu at gcc dot gnu dot org
@ 2007-03-13 16:22 ` manu at gcc dot gnu dot org
1 sibling, 0 replies; 5+ messages in thread
From: manu at gcc dot gnu dot org @ 2007-03-13 16:22 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from manu at gcc dot gnu dot org 2007-03-13 16:22 -------
and as such, this is a duplicate of bug 16351.
*** This bug has been marked as a duplicate of 16351 ***
--
manu at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |DUPLICATE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30368
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug c/30368] missing warning for dereferencing null pointer
2007-01-04 14:21 [Bug c/30368] New: wrong result lidaobing at gmail dot com
@ 2007-03-13 16:13 ` manu at gcc dot gnu dot org
2007-03-13 16:22 ` manu at gcc dot gnu dot org
1 sibling, 0 replies; 5+ messages in thread
From: manu at gcc dot gnu dot org @ 2007-03-13 16:13 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from manu at gcc dot gnu dot org 2007-03-13 16:12 -------
So the conclusion is that we should emit a warning for the undefinedness.
--
manu at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2007-03-13 16:12:46
date| |
Summary|wrong result |missing warning for
| |dereferencing null pointer
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30368
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-12-18 11:24 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-30368-4@http.gcc.gnu.org/bugzilla/>
2013-11-19 6:29 ` [Bug c/30368] missing warning for dereferencing null pointer law at redhat dot com
2020-05-19 0:09 ` msebor at gcc dot gnu.org
2021-12-18 11:24 ` egallager at gcc dot gnu.org
2007-01-04 14:21 [Bug c/30368] New: wrong result lidaobing at gmail dot com
2007-03-13 16:13 ` [Bug c/30368] missing warning for dereferencing null pointer manu at gcc dot gnu dot org
2007-03-13 16:22 ` manu at gcc dot gnu dot org
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).