Bug 19290 - cpp truncates long lines with no warning
Summary: cpp truncates long lines with no warning
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: cpp   
(Show other bugs)
Version: 7.0
Hardware: i386
OS: Linux
medium
high
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact:
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2000-10-17 23:10 UTC by henry
Modified: 2008-05-01 15:37 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-11-13 11:17:19 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2000:132 normal SHIPPED_LIVE Bug fixing update of GCC 2.96 2000-12-19 05:00:00 UTC

Description henry 2000-10-17 23:10:21 UTC
The cpp shipped with Red Hat 7.0, at least on Intel hardware, silently
truncates long (and I mean very long) lines.  This showed up in complaints
from users trying to recompile MLton (our ML compiler).
As a simple test case, consider the C source file

	int
	a(int b)
	{
		int	c;

		c = b + b + b + ... + b;
		return (c);
	}
where you include 100,000 b's (so the line will have 400,004 bytes in it).
If you run this through `gcc -E', the output will only be about 7000 bytes
wide and will end in a `+', the rest having been discarded.

Please note, these lines would be rather ridiculous if generated by hand,
but they are the output of our compiler.  Automatically generated C is
quite common (consider the output of yacc, or lex for instance).
It is a real disaster that not only does cpp fail, but it fails silently,
with no error message and no funny exit status.

Comment 1 Cristian Gafton 2000-10-17 23:33:54 UTC
assigned to jakub

Comment 2 Jakub Jelinek 2000-11-13 11:17:16 UTC
Will be fixed in cpp-2.96-64.


Note You need to log in before you can comment on or make changes to this bug.