Debian Bug report logs - #534193
libstdc++6: calling erase() on a new empty string will cause a helgrind error report

version graph

Package: libstdc++6; Maintainer for libstdc++6 is Debian GCC Maintainers <debian-gcc@lists.debian.org>; Source for libstdc++6 is src:gcc-4.9.

Reported by: Russell Coker <russell@coker.com.au>

Date: Mon, 22 Jun 2009 12:03:02 UTC

Severity: important

Found in version gcc-4.3/4.3.2-1.1

Fixed in version 4.4.4-1

Done: Matthias Klose <doko@debian.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Debian GCC Maintainers <debian-gcc@lists.debian.org>:
Bug#534193; Package libstdc++6. (Mon, 22 Jun 2009 12:03:04 GMT) Full text and rfc822 format available.

Acknowledgement sent to Russell Coker <russell@coker.com.au>:
New Bug report received and forwarded. Copy sent to Debian GCC Maintainers <debian-gcc@lists.debian.org>. (Mon, 22 Jun 2009 12:03:04 GMT) Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Russell Coker <russell@coker.com.au>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: libstdc++6: calling erase() on a new empty string will cause a helgrind error report
Date: Mon, 22 Jun 2009 21:59:49 +1000
Package: libstdc++6
Version: 4.3.2-1.1
Severity: important

http://etbe.coker.com.au/2009/06/22/valgrindhelgrind-and-stl-string
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40518

The above GCC bug report which was created by Jonathan Wakely after reading my
blog concerns a case where calling empty() on an empty string will be regarded
as not being thread-safe by helgrind.

I am not sure if this is a real problem (IE something that can corrupt memory)
or whether it's a cosmetic error (something that just causes helgrind
warnings).  Due to this being the main error that helgrind flags on a program
that later has an assertion from free() I suspect that it may actually
corrupt memory.  But if however it happens to not corrupt memory I still think
that it is important enough to justify an update to Lenny to fix this.

Allowing debugging tools such as helgrind to work to their maximum potential
is quite important to improve the overall quality of the code.

I have reproduced this bug in version 4.3.3-12 in Unstable.

-- System Information:
Debian Release: 5.0.1
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: i386 (i686)

Kernel: Linux 2.6.26-1-686 (SMP w/1 CPU core)
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=ANSI_X3.4-1968) (ignored: LC_ALL set to C)
Shell: /bin/sh linked to /bin/bash

Versions of packages libstdc++6 depends on:
ii  gcc-4.3-base                 4.3.2-1.1   The GNU Compiler Collection (base 
ii  libc6                        2.7-18      GNU C Library: Shared libraries
ii  libgcc1                      1:4.3.2-1.1 GCC support library

libstdc++6 recommends no packages.

libstdc++6 suggests no packages.

-- no debconf information




Reply sent to Matthias Klose <doko@debian.org>:
You have taken responsibility. (Tue, 22 Jun 2010 12:36:11 GMT) Full text and rfc822 format available.

Notification sent to Russell Coker <russell@coker.com.au>:
Bug acknowledged by developer. (Tue, 22 Jun 2010 12:36:11 GMT) Full text and rfc822 format available.

Message #10 received at 534193-done@bugs.debian.org (full text, mbox):

From: Matthias Klose <doko@debian.org>
To: Russell Coker <russell@coker.com.au>, 534193-done@bugs.debian.org
Subject: Re: Bug#534193: libstdc++6: calling erase() on a new empty string will cause a helgrind error report
Date: Tue, 22 Jun 2010 14:33:27 +0200
Version: 4.4.4-1

On 22.06.2009 13:59, Russell Coker wrote:
> Package: libstdc++6
> Version: 4.3.2-1.1
> Severity: important
>
> http://etbe.coker.com.au/2009/06/22/valgrindhelgrind-and-stl-string
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40518
>
> The above GCC bug report which was created by Jonathan Wakely after reading my
> blog concerns a case where calling empty() on an empty string will be regarded
> as not being thread-safe by helgrind.
>
> I am not sure if this is a real problem (IE something that can corrupt memory)
> or whether it's a cosmetic error (something that just causes helgrind
> warnings).  Due to this being the main error that helgrind flags on a program
> that later has an assertion from free() I suspect that it may actually
> corrupt memory.  But if however it happens to not corrupt memory I still think
> that it is important enough to justify an update to Lenny to fix this.
>
> Allowing debugging tools such as helgrind to work to their maximum potential
> is quite important to improve the overall quality of the code.




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Wed, 21 Jul 2010 07:37:28 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Sat Apr 19 15:16:11 2014; Machine Name: beach.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.