[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#185242: marked as done (libstdc++5-dev: rope segfaults under heavy load)



Your message dated Sun, 6 Jul 2003 09:37:12 +0200
with message-id <16135.53672.192466.790645@gargle.gargle.HOWL>
and subject line Bug#185242: libstdc++5-dev: rope segfaults under heavy load
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--------------------------------------
Received: (at submit) by bugs.debian.org; 18 Mar 2003 04:44:38 +0000
>From vectro@pipeline.com Mon Mar 17 22:44:38 2003
Return-path: <vectro@pipeline.com>
Received: from cats-mx1.ucsc.edu (ucsc.edu) [128.114.129.36] 
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 18v8xq-0007E7-00; Mon, 17 Mar 2003 22:44:38 -0600
Received: from chimaera.house (C9-dhcp-21-235.resnet.ucsc.edu [169.233.21.235])
	by ucsc.edu (8.10.1/8.10.1) with ESMTP id h2I4iKk13899
	for <submit@bugs.debian.org>; Mon, 17 Mar 2003 20:44:20 -0800 (PST)
Received: from crafter.house ([192.168.1.1])
	by chimaera.house with esmtp (Exim 3.35 #1 (Debian))
	id 18v8xb-0007cu-00
	for <submit@bugs.debian.org>; Mon, 17 Mar 2003 20:44:23 -0800
Received: from vectro by crafter.house with local (Exim 3.36 #1 (Debian))
	id 18v8xP-0001IL-00; Mon, 17 Mar 2003 20:44:11 -0800
From: Ian Turner <vectro@pipeline.com>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: libstdc++5-dev: rope segfaults under heavy load
X-Mailer: reportbug 1.50
Date: Mon, 17 Mar 2003 20:44:11 -0800
Message-Id: <E18v8xP-0001IL-00@crafter.house>
X-UCSC-CATS-MailScanner: Found to be clean
Delivered-To: submit@bugs.debian.org
X-Spam-Status: No, hits=-0.2 required=4.0
	tests=HAS_PACKAGE,SPAM_PHRASE_00_01
	version=2.44
X-Spam-Level: 

Package: libstdc++5-dev
Version: 1:3.2.3-0pre5
Severity: important

Consider the following program:

--- BEGIN ropetest.c ---
#include <ext/rope>

using namespace std;
using namespace __gnu_cxx;

unsigned int rand(unsigned int max) {
  unsigned int rval = (unsigned int)(((double)max)*rand()/(RAND_MAX));
  if (rval == max)
    return max-1;
}

int main() {
  crope r;
  char buf[10240];
  
  while (1) {
    if (rand(2) && r.size() < 1024*1024) {
      r.append(buf, rand(10240));
    } else if (r.size() > 10240) {
      r.erase(0, rand(10240));
    }
  }
  return 0;
}
--- END ropetest.c ---

It crashes when compiled with g++-3.0 or g++-3.2 (but not on g++ 2.95):

$ g++ ropetest.c -o ropetest-295 -Wall
$ ./ropetest-295
[ press CTRL-C ]
$ g++-3.0 ropetest.c -o ropetest-300 -Wall
$ ./ropetest-300
Segmentation fault
$ g++-3.2 ropetest.c -o ropetest-320 -Wall -g
$ ./ropetest-320
Aborted

$ gdb g++-3.2
GNU gdb 5.3-debian
[ snip ]
(gdb) run
Starting program: ropetest-320

Program received signal SIGABRT, Aborted.
0x40113a51 in kill () from /lib/libc.so.6
(gdb) bt
#0  0x40113a51 in kill () from /lib/libc.so.6
#1  0x40113872 in raise () from /lib/libc.so.6
#2  0x40114986 in abort () from /lib/libc.so.6
#3  0x4009a9a0 in __cxa_call_unexpected () from /usr/lib/libstdc++.so.5
#4  0x4009a9e4 in std::terminate() () from /usr/lib/libstdc++.so.5
#5  0x4009ab31 in __cxa_throw () from /usr/lib/libstdc++.so.5
#6  0x4009ace1 in operator new(unsigned) () from /usr/lib/libstdc++.so.5
#7  0x4008a4c9 in std::allocator<char>::allocate(unsigned, void const*) ()
   from /usr/lib/libstdc++.so.5
#8  0x0804935f in __gnu_cxx::rope<char, std::allocator<char> >::_S_RopeLeaf_from_unowned_char_ptr(char const*, unsigned, std::allocator<char>) (
    __s=0xbfffd190 "", __size=1073779424, __a={<No data fields>})
    at /usr/include/c++/3.2/ext/stl_rope.h:1412
#9  0x08048eef in __gnu_cxx::rope<char, std::allocator<char> >::_S_destr_concat_char_iter(__gnu_cxx::_Rope_RopeRep<char, std::allocator<char> >*, char const*, unsigned) (__r=0x0, __s=0xbfffd190 "", __slen=1073779424)
    at /usr/include/c++/3.2/ext/ropeimpl.h:557
#10 0x08048e2d in __gnu_cxx::rope<char, std::allocator<char> >::append(char const*, unsigned) (this=0xbffff9a0, __iter=0xbfffd190 "", __n=1073779424)
    at /usr/include/c++/3.2/ext/stl_rope.h:1795
#11 0x08048c6b in main () at ropetest.cc:19


-- System Information
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux crafter 2.4.19 #1 Fri Sep 27 18:25:53 PDT 2002 i686
Locale: LANG=C, LC_CTYPE=C

Versions of packages libstdc++5-dev depends on:
ii  g++-3.2                    1:3.2.3-0pre5 The GNU C++ compiler
ii  gcc-3.2-base               1:3.2.3-0pre5 The GNU Compiler Collection (base 
ii  libc6-dev                  2.3.1-14      GNU C Library: Development Librari
ii  libstdc++5                 1:3.2.3-0pre5 The GNU Standard C++ Library v3


---------------------------------------
Received: (at 185242-done) by bugs.debian.org; 6 Jul 2003 07:39:56 +0000
>From doko@cs.tu-berlin.de Sun Jul 06 02:39:54 2003
Return-path: <doko@cs.tu-berlin.de>
Received: from mail.cs.tu-berlin.de [130.149.17.13] 
	by master.debian.org with esmtp (Exim 3.35 1 (Debian))
	id 19Z47l-0002uo-00; Sun, 06 Jul 2003 02:39:53 -0500
Received: from bolero.cs.tu-berlin.de (daemon@bolero.cs.tu-berlin.de [130.149.19.1])
	by mail.cs.tu-berlin.de (8.9.3/8.9.3) with ESMTP id JAA21214
	for <185242-done@bugs.debian.org>; Sun, 6 Jul 2003 09:37:12 +0200 (MET DST)
Received: (from doko@localhost)
	by bolero.cs.tu-berlin.de (8.11.6+Sun/8.9.3) id h667bCq01987;
	Sun, 6 Jul 2003 09:37:12 +0200 (MEST)
From: Matthias Klose <doko@cs.tu-berlin.de>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Message-ID: <16135.53672.192466.790645@gargle.gargle.HOWL>
Date: Sun, 6 Jul 2003 09:37:12 +0200
To: 185242-done@bugs.debian.org
Subject: Re: Bug#185242: libstdc++5-dev: rope segfaults under heavy load
X-Mailer: VM 7.03 under 21.4 (patch 6) "Common Lisp" XEmacs Lucid
Delivered-To: 185242-done@bugs.debian.org
X-Spam-Status: No, hits=-2.0 required=4.0
	tests=BAYES_01,USER_AGENT_VM
	version=2.53-bugs.debian.org_2003_06_27
X-Spam-Level: 
X-Spam-Checker-Version: SpamAssassin 2.53-bugs.debian.org_2003_06_27 (1.174.2.15-2003-03-30-exp)

Not reproducible anymore with current g++-3.2 and g++-3.3, no feedback
received since Thu, 17 Apr 2003 21:36:48 +0200



Reply to: