Bug 166392 - g++ crashes when compiling code - please see Description and Additional Information
g++ crashes when compiling code - please see Description and Additional Infor...
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: gcc (Show other bugs)
3
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2005-08-20 07:28 EDT by Tadeusz Struk
Modified: 2007-11-30 17:11 EST (History)
0 users

See Also:
Fixed In Version: 3.4.3-22.fc3
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-08-24 04:17:52 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


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

  None (edit)
Description Tadeusz Struk 2005-08-20 07:28:14 EDT
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 13:02:29 EDT
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 05:02:39 EDT
Created attachment 117962 [details]
preprocessed source
Comment 3 Jakub Jelinek 2005-08-24 04:17:52 EDT
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.