This is the mail archive of the
gcc-prs@gcc.gnu.org
mailing list for the GCC project.
Re: preprocessor/9465: tradcpp0 segfaults on nul bytes
- From: Neil Booth <neil at daikokuya dot co dot uk>
- To: nobody at gcc dot gnu dot org
- Cc: gcc-prs at gcc dot gnu dot org,
- Date: 27 Jan 2003 22:16:00 -0000
- Subject: Re: preprocessor/9465: tradcpp0 segfaults on nul bytes
- Reply-to: Neil Booth <neil at daikokuya dot co dot uk>
The following reply was made to PR preprocessor/9465; it has been noted by GNATS.
From: Neil Booth <neil@daikokuya.co.uk>
To: Alexandre Duret-Lutz <adl@gnu.org>
Cc: gcc-gnats@gcc.gnu.org, Jakub Jelinek <jakub@redhat.com>,
gcc-bugs@gcc.gnu.org
Subject: Re: preprocessor/9465: tradcpp0 segfaults on nul bytes
Date: Mon, 27 Jan 2003 22:08:13 +0000
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.