X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-0.2 required=5.0 tests=AWL,BAYES_50,RCVD_IN_DNSWL_NONE,RP_MATCHES_RCVD,TW_YG,UNPARSEABLE_RELAY X-Spam-Check-By: sourceware.org Message-ID: <4E7CE6AF.7010308@t-online.de> Date: Fri, 23 Sep 2011 22:06:07 +0200 From: Christian Franke User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: gcc4: libstdc++6-4.5.3-2 is probably not backwards compatible Content-Type: multipart/mixed; boundary="------------050102050206090308050005" X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com --------------050102050206090308050005 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit ddrescue segfaults in option parsing after gcc was updated from 4.3.4-4 to 4.5.3-2. (ddrescue package was build with g++ 4.3.4-3) I tracked down the problem to a segfault in vector< string > destructor, see attached testcase. 1. Compile and run with g++ 4.3.4, use -O2 to enable inline expansion: $ g++ -O2 -o testvector testvector.cpp $ cygcheck -f /bin/cygstdc++-6.dll libstdc++6-4.3.4-4 $ ./testvector vector created (12) vector destroyed 2. Update libstdc++ and rerun: $ cygcheck -f /bin/cygstdc++-6.dll libstdc++6-4.5.3-2 $ ./testvector vector created (12) Aborted (core dumped) Recompiling with new g++ fixes the problem. Old inline code is probably no longer compatible with code in new cygstdc++-6.dll. -- Regards, Christian Franke --------------050102050206090308050005 Content-Type: text/plain; name="testvector.cc" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="testvector.cc" #include #include #include int main() { { std::vector v; v.resize(1); printf("vector created (%d)\n", (int)sizeof(v)); fflush(stdout); } printf("vector destroyed\n"); fflush(stdout); return 0; } --------------050102050206090308050005 Content-Type: text/plain; charset=us-ascii -- 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 --------------050102050206090308050005--