X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=0.2 required=5.0	tests=AWL,BAYES_05,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,T_TO_NO_BRKTS_FREEMAIL
X-Spam-Check-By: sourceware.org
MIME-Version: 1.0
In-Reply-To: <68B76592-8AB8-4CE6-A75D-5EEB857D500A@flashpixx.de>
References: <68B76592-8AB8-4CE6-A75D-5EEB857D500A@flashpixx.de>
Date: Sat, 16 Jul 2011 15:02:21 +0200
Message-ID: <CAAWYfq02G-rq6Up3Vq1_ioh+M==1KTRubgF0L3N4Y-pa0tmfhQ@mail.gmail.com>
Subject: Re: exception under g++
From: Dima Pasechnik <dimpase@gmail.com>
To: cygwin@cygwin.com
Content-Type: text/plain; charset=UTF-8
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

Hi Phil,
you ought to post steps to reproduce the problem, if there is one.
By the way, can you check that you link against libgcc using -shared-libgcc?

You can also try to figure out whether is this not a purely g++ problem, by
installing g++ 4.3.4 on Linux, say, and trying your code with it.

On 16 July 2011 12:53, Kraus Philipp <philipp.kraus@flashpixx.de> wrote:
> Hello,
>
> I'm using Cygwin for compiling my C++ sources under Windows. My code is throwing an exception (I know the exception and the position within the code), but under the binary that is compiled under Cygwin I get the message:
> terminate called after throwing an instance of [...] terminate called recursively
>
> The same code word under OSX 10.5, 10.6 and Linux x64. The different between the systems are only the versions of the g++:
> Cygwin 4.3.4
> OSX 4.2.1
> Linux 4.5.2
>
> I try to understand in which way I can solve this problem. The code throws the exception and on top / on the main a try-catch block should be catch this exception, but it does not work.
> Does anyone have some ideas for this problem? I don't understand why Windows should create other structures than the other systems.

Windows has a number of ways to handle exceptions, e.g. MSVC++
exceptions used to be (or maybe are, still) not conforming to C++
standard.

>
> Thanks a lot
>
> Phil
>
>
> --

Dmitrii

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

