This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: preprocessor/9465: tradcpp0 segfaults on nul bytes


Alexandre Duret-Lutz wrote:-

> >Originator:     Alexandre Duret-Lutz
> >Release:        cpp (GCC) 3.2.2 20030124 (Debian prerelease)
> >Organization:
> >Environment:
> Debian unstable
> >Description:
> `tradcpp0' segfaults on nul bytes.
> 
> When Debian switched to gcc-3.2 my applications' X resources
> stopped being honored.  It turns out that `xrdb' processes
> its input with `cpp -traditional' and I had a useless nul byte
> at the end of my .Xresources.
> 
> I can reproduce this segfault with 3.1.  It works fine with 2.95.
> >How-To-Repeat:
> Create a file containing a nul byte, and run it through
> the traditional preproc.
> 
> % echo '\0' > bar
> % od -c bar
> 0000000  \0  \n
> 0000002
> ~ % cpp bar
> # 1 "bar"
> # 1 "<built-in>"
> # 1 "<command line>"
> # 1 "bar"
> bar:1:1: warning: null character(s) ignored
> ~ % cpp -traditional bar
> cpp: Internal error: Segmentation fault (program tradcpp0)

Jakub, this is the second report of this regression you introduced.

Do you intend to fix it?

Neil.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]