public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug pch/35027] New: "too short to be a PCH file" warning should be conditional on -Winvalid-PCH
@ 2008-01-30 1:12 pinskia at gcc dot gnu dot org
2008-01-30 1:20 ` [Bug pch/35027] " pinskia at gcc dot gnu dot org
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-01-30 1:12 UTC (permalink / raw)
To: gcc-bugs
If someone puts a .d file in a .gch directory, we will still warn even if the
user did not use -Winvalid-PCH. All other reasons why we would reject a PCH
including an invalid magic is conditionalized on -Winvalid-PCH so should this
warning.
--
Summary: "too short to be a PCH file" warning should be
conditional on -Winvalid-PCH
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Keywords: diagnostic
Severity: normal
Priority: P3
Component: pch
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pinskia at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35027
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug pch/35027] "too short to be a PCH file" warning should be conditional on -Winvalid-PCH
2008-01-30 1:12 [Bug pch/35027] New: "too short to be a PCH file" warning should be conditional on -Winvalid-PCH pinskia at gcc dot gnu dot org
@ 2008-01-30 1:20 ` pinskia at gcc dot gnu dot org
2008-02-23 17:09 ` pinskia at gcc dot gnu dot org
2008-02-23 17:09 ` pinskia at gcc dot gnu dot org
2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-01-30 1:20 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from pinskia at gcc dot gnu dot org 2008-01-30 00:43 -------
I have a simple fix for 4.4.0:
Index: c-pch.c
===================================================================
--- c-pch.c (revision 131943)
+++ c-pch.c (working copy)
@@ -243,8 +243,9 @@
fatal_error ("can%'t read %s: %m", name);
else if (sizeread != IDENT_LENGTH + 16)
{
- cpp_error (pfile, CPP_DL_WARNING, "%s: too short to be a PCH file",
- name);
+ if (cpp_get_options (pfile)->warn_invalid_pch)
+ cpp_error (pfile, CPP_DL_WARNING, "%s: too short to be a PCH file",
+ name);
return 2;
}
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
OtherBugsDependingO| |33702
nThis| |
AssignedTo|unassigned at gcc dot gnu |pinskia at gcc dot gnu dot
|dot org |org
Status|UNCONFIRMED |ASSIGNED
Ever Confirmed|0 |1
Last reconfirmed|0000-00-00 00:00:00 |2008-01-30 00:43:57
date| |
Target Milestone|--- |4.4.0
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35027
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug pch/35027] "too short to be a PCH file" warning should be conditional on -Winvalid-PCH
2008-01-30 1:12 [Bug pch/35027] New: "too short to be a PCH file" warning should be conditional on -Winvalid-PCH pinskia at gcc dot gnu dot org
2008-01-30 1:20 ` [Bug pch/35027] " pinskia at gcc dot gnu dot org
@ 2008-02-23 17:09 ` pinskia at gcc dot gnu dot org
2008-02-23 17:09 ` pinskia at gcc dot gnu dot org
2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-02-23 17:09 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from pinskia at gcc dot gnu dot org 2008-02-23 17:08 -------
Subject: Bug 35027
Author: pinskia
Date: Sat Feb 23 17:08:12 2008
New Revision: 132574
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=132574
Log:
2008-02-23 Andrew Pinski <andrew_pinski@playstation.sony.com>
PR pch/35027
* c-pch.c (c_common_valid_pch): Make the "too short to be a PCH
file" warning condtional on -Winvalid-PCH.
Modified:
trunk/gcc/ChangeLog
trunk/gcc/c-pch.c
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35027
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug pch/35027] "too short to be a PCH file" warning should be conditional on -Winvalid-PCH
2008-01-30 1:12 [Bug pch/35027] New: "too short to be a PCH file" warning should be conditional on -Winvalid-PCH pinskia at gcc dot gnu dot org
2008-01-30 1:20 ` [Bug pch/35027] " pinskia at gcc dot gnu dot org
2008-02-23 17:09 ` pinskia at gcc dot gnu dot org
@ 2008-02-23 17:09 ` pinskia at gcc dot gnu dot org
2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-02-23 17:09 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from pinskia at gcc dot gnu dot org 2008-02-23 17:08 -------
Fixed.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35027
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-02-23 17:09 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-01-30 1:12 [Bug pch/35027] New: "too short to be a PCH file" warning should be conditional on -Winvalid-PCH pinskia at gcc dot gnu dot org
2008-01-30 1:20 ` [Bug pch/35027] " pinskia at gcc dot gnu dot org
2008-02-23 17:09 ` pinskia at gcc dot gnu dot org
2008-02-23 17:09 ` pinskia 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).