Bug 166392 - g++ crashes when compiling code - please see Description and Additional Information
Summary: g++ crashes when compiling code - please see Description and Additional Infor...
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc
Version: 3
Hardware: i686
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact:
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-08-20 11:28 UTC by Tadeusz Struk
Modified: 2007-11-30 22:11 UTC (History)
0 users

(edit)
Clone Of:
(edit)
Last Closed: 2005-08-24 08:17:52 UTC


Attachments (Terms of Use)
preprocessed source (1.50 MB, text/plain)
2005-08-22 09:02 UTC, Tadeusz Struk
no flags Details

Description Tadeusz Struk 2005-08-20 11:28:14 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; rv:1.7.3) Gecko/20041020 Firefox/0.10.1

Description of problem:
g++ -c -ggdb -p -g `mico-config --cxxflags` -I. -I./include -I../include -I/home/tadeusz/devel/core/include -I/usr/include/c++/3.4.2 -c ../src/ServerAdmin.cpp
../src/ServerAdmin.cpp: In member function `int IMServerAdmin::localInit()':
../src/ServerAdmin.cpp:68: internal compiler error: in tree_low_cst, at tree.c:3318
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla> for instructions.
Preprocessed source stored into /tmp/ccGZI0YG.out file, please attach this to your bugreport.
gmake: *** [../src/ServerAdmin.o] Error 1

/tmp/ccGZI0YG.out file is a 1,5MB of code. I'll send it if you let me know how you would like to receive it.





Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
g++ -c -ggdb -p -g `mico-config --cxxflags` -I. -I./include -I../include -I/home/tadeusz/devel/core/include -I/usr/include/c++/3.4.2 -c ../src/ServerAdmin.cpp

Actual Results:  ../src/ServerAdmin.cpp: In member function `int IMServerAdmin::localInit()':
../src/ServerAdmin.cpp:68: internal compiler error: in tree_low_cst, at tree.c:3318

Expected Results:  valid object file

Additional info:


int IMServerAdmin::localInit()
{
      m_config = coreConfig::getInstance();
      m_log = coreLog::getInstance();

int ac = 1;
char* av[0] = {"../bin/IMServer"};


      m_orb = CORBA::ORB_init(ac, av);
      CORBA::Object_var obj = m_orb->resolve_initial_references("RootPOA");
      PortableServer::POA_var rootPOA = PortableServer::POA::_narrow(obj);
      PortableServer::POAManager_var mgr = rootPOA->the_POAManager();
      m_server = new IMServerImpl;
      PortableServer::ObjectId_var objId = rootPOA->activate_object(m_server);
      CORBA::Object_var ref = rootPOA->id_to_reference(objId.in());
      m_serverIOR = m_orb->object_to_string(ref.in());
      for(int i=0; i < m_argc; i++)
 cout<< "From Local init() " << m_argv[i] <<endl;
      return 0;
}

Comment 1 Jakub Jelinek 2005-08-20 17:02:29 UTC
The compiler driver told you:
Preprocessed source stored into /tmp/ccGZI0YG.out file, please attach this to
your bugreport.
Please do so, preprocessed source is really crucial to reproduce any compiler
bug.


Comment 2 Tadeusz Struk 2005-08-22 09:02:39 UTC
Created attachment 117962 [details]
preprocessed source

Comment 3 Jakub Jelinek 2005-08-24 08:17:52 UTC
Do you have your system updated?
Can't reproduce it:
rpm -q gcc-c++; g++ -m32 -march=i386 -ggdb -g -O2 -Wall -p 166392.ii
gcc-c++-3.4.3-22
../src/ServerAdmin.cpp: In member function `int IMServerAdmin::localInit()':
../src/ServerAdmin.cpp:68: error: excess elements in aggregate initializer
And similarly with the latest FC3 gcc update, 3.4.4-2.fc3.

The bug in question is in:
char* av[0] = {"../bin/IMServer"};
Of course a zero element array can't have non-empty initializers.


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