This is the mail archive of the
gcc-prs@gcc.gnu.org
mailing list for the GCC project.
c/1496: gcc 2.95.2 results in runtime segmentation fault
- To: gcc-gnats at gcc dot gnu dot org
- Subject: c/1496: gcc 2.95.2 results in runtime segmentation fault
- From: murali at mpi-softtech dot com
- Date: 22 Dec 2000 11:55:03 -0000
- Cc: admin at mpi-softtech dot com
- Reply-To: murali at mpi-softtech dot com
>Number: 1496
>Category: c
>Synopsis: gcc 2.95.2 results in runtime segmentation fault
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Dec 22 03:56:01 PST 2000
>Closed-Date:
>Last-Modified:
>Originator: murali@mpi-softtech.com
>Release: gcc version 2.95.2 19991024 (release)
>Organization:
>Environment:
sparc-sun-solaris2.7/2.95.2
>Description:
There is only one executable line in the code below.
I used gcc test.c to compile i.e. no options. When I run,
I get a segmentation fault.
a.out
Segmentation Fault (core dumped)
>How-To-Repeat:
#include "stdio.h"
int main(void)
{
int* a;
int* b;
*b = 3 ;
return 0;
}
>Fix:
I tried to insert a line
int c;
between the two pointer declarations. Then, it works.
>Release-Note:
>Audit-Trail:
>Unformatted: