Bug 109961 - Problem with c++ exceptions after upgrading libc
Summary: Problem with c++ exceptions after upgrading libc
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: glibc
Version: 9
Hardware: i686
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact: Brian Brock
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2003-11-13 14:33 UTC by Johan Lagerros
Modified: 2016-11-24 15:22 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2003-11-13 16:40:04 UTC
Embargoed:


Attachments (Terms of Use)

Description Johan Lagerros 2003-11-13 14:33:52 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1)
Gecko/20030225

Description of problem:
Exceptions in C++ programs results in SIGABRT, instead of being caught.
For example, compiling and running this test program on an
glibc-2.3.2-27.9 machine works fine (prints "OK!"), but not for
glibc-2.3.2-27.9.6:

#include <iostream>

int main(void)
{
  try {
    throw int(3);
  }

  catch (int& e) {
    std::cout << "OK!" << std::endl;
  }

  return 0;
}


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

How reproducible:
Always

Steps to Reproduce:
1. Compile testprogram (c++ -o example example.cpp)
2. Run testprogram (./example)

    

Actual Results:  % ./example
Aborted
% 

Expected Results:  % ./example
OK!
%


Additional info:

Comment 1 Jakub Jelinek 2003-11-13 15:02:15 UTC
Cannot reproduce.
Can you run:
uname -a
ldd ./example
strace ./example
?

Comment 2 Johan Lagerros 2003-11-13 16:40:04 UTC
I'm so sorry! Running "ldd ./example" showed that I was linking to an
old library. Removing that solved the problem!


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