Bug 18039 - g++ breaks glibc
Summary: g++ breaks glibc
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: gcc (Show other bugs)
(Show other bugs)
Version: 7.0
Hardware: i386 Linux
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2000-10-01 22:20 UTC by Stefan Sorensen
Modified: 2008-05-01 15:37 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2000-10-02 21:47:44 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Stefan Sorensen 2000-10-01 22:20:05 UTC

extern "C" {
void exit (int);
#include <stdlib.h>

with g++ yields:

In file included from foo.cpp:6:
/usr/include/stdlib.h:578: declaration of `void exit (int) throw ()'  
throws different exceptions
foo.cpp:2: than previous declaration `void exit (int)'

This breaks autoconf scripts which includes stdlib.h in a AC_TRY_RUN when
language is set to c++.

Seems to be the same as described at

Comment 1 jiefg 2000-10-02 02:13:13 UTC
...tells a lot about what kind of testing RedHat does before launching a new
product. This is VERY frustrating.

Comment 2 Bernhard Rosenkraenzer 2000-10-02 21:47:41 UTC
This is not a bug. void exit(int) is a redefinition because the exit() prototype
in stdlib.h throws exceptions.

Comment 3 Jakub Jelinek 2000-10-03 05:55:25 UTC
As bero mentioned, this really is not a bug and it is good current g++
is more strict about user bugs than it used to. Write correct C++
code and you should get of this warning. If current GNU autoconf
still generates this code it should be fixed, will check it out.

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