Bug 54952 - Core dump when exception thrown if linked library compiled with older gcc
Core dump when exception thrown if linked library compiled with older gcc
Status: CLOSED NOTABUG
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
7.1
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-10-23 13:31 EDT by Martin Frydl
Modified: 2007-04-18 12:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2001-10-23 13:34:57 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Source code causing the core dumps when linked with Xerces (233 bytes, text/plain)
2001-10-23 13:34 EDT, Martin Frydl
no flags Details

  None (edit)
Description Martin Frydl 2001-10-23 13:31:14 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.77 [en] (X11; U; Linux 2.4.5 i686)

Description of problem:
I have a simple program throwing and catching the exception. Alone it works
fine, but when I link it with Xerces-C++ library it dumps core. The program
itself in fact does not need the library.

I use precompiled Xerces 1.5.1 from
http://xml.apache.org/dist/xerces-c/stable/ It was compiled on RedHat 6.1
with egcs-2.91.66 and glibc-2.1.2-11 (from Xerces-C++ FAQ on
xml.apache.org/xerces-c)

I do this:
Works:
	gcc -o test test.cpp
Compiles, but segfaults when run:
	gcc -o test test.cpp -lxerces-c1_5_1

I'm using gcc-2.96-85 from latest updates.


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


How reproducible:
Always

Steps to Reproduce:
1.Compile using gcc -o test test.cpp -lxerces-c1_5_1
2.Run it
	

Additional info:
Comment 1 Martin Frydl 2001-10-23 13:34:53 EDT
Created attachment 34763 [details]
Source code causing the core dumps when linked with Xerces
Comment 2 Jakub Jelinek 2001-11-12 09:11:49 EST
You cannot mix code compiled with different C++ compilers.
Either all libs and main program have to be compiled with egcs 1.1.x, or
gcc 2.95.x, or 2.96-RH, or 3.0, or 3.1, no mixing is possible.

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