This is the mail archive of the
mailing list for the Cygwin project.
Re: BUG - Cygwin to GNU CC compatibility
- From: swamp-dog at ntlworld dot com (Guy Harrison)
- To: <cygwin at cygwin dot com>
- Date: Mon, 05 Aug 2002 17:30:13 GMT
- Subject: Re: BUG - Cygwin to GNU CC compatibility
- References: <OE73cChrBb2iDChs0u900007f12@hotmail.com>
On Mon, 5 Aug 2002 23:47:03 +1000, "Arash Partow" <firstname.lastname@example.org>
>I've found a certain combination of simple code that is totally compatible
>with unix/linux GNU compilers and runs perfectly on those OSs however
>even though it compiles fine using Cygwin g++, causes the program to crash
>under windows when executed.
You were unlucky (that it worked at all).
>The demo program is a simple counter example written in C++, no fancy
>code, or special coding tricks have been used. The only libs used are:
>stdio, stdlib and iostream.
>The error occurs on a particular malloc, as state before the program runs
>fine on all unix based systems and I was able to compile it with Borland C++
>Builder 6.0 and the produced executable ran fine on windows.
>I've tried running the cygwin produced executable on Win95,98,2K,XP,NT
>and on all these OSs the program will crash.
>I'm using the latest version of cygwin compiler system as of the 2nd of Aug.
>I have no idea on how to go around fixing a patch for this cause i'm not
>where to begin, there are a number of places for which such an error like
>can occur, I think it maybe something to do with the Cygwin DLL.
>I have uploaded the sourcode, makefile, executable and a copy of my cygwin
>checkout, the url is:
>to make the application type:
>to run the application type:
>If anyone has any suggestions or ideas to fix this BUG can you please e-mail
>ASAP, any other help on how to avoid this bug until someone can come up with
>a patch would be very much appreciated.
std::string dig1("123"); //or std::vector<int> + push_back
>PS: The malloc in question can be found on line 114 of DigitList.cpp
Most often a symptom of earlier problems. Nothing wrong with the DLL or
gcc here, just language issues. Try alt.comp.lang.learn.c-c++ for an
explanation (for instance) of what is really happening in your copy
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html