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

Bug#272219: marked as done (Valgrind bug probably due to libc6)



Your message dated Sat, 25 Sep 2004 11:10:52 +0900
with message-id <81wtyjnln7.wl@omega.webmasters.gr.jp>
and subject line Bug#272219: Valgrind bug probably due to libc6
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 Sep 2004 13:01:36 +0000
>From claus.fischer@clausfischer.com Sat Sep 18 06:01:36 2004
Return-path: <claus.fischer@clausfischer.com>
Received: from 213-239-206-67.clients.your-server.de (clausfischer.com) [213.239.206.67] 
	by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
	id 1C8eqO-0005KE-00; Sat, 18 Sep 2004 06:01:36 -0700
Received: from boltzmann.strudlhofstiege (localhost [127.0.0.1])
	by clausfischer.com (Postfix) with ESMTP id 99DE8410019
	for <submit@bugs.debian.org>; Sat, 18 Sep 2004 15:01:34 +0200 (CEST)
Received: from doppler.strudlhofstiege (doppler.strudlhofstiege [10.243.1.5])
	by boltzmann.strudlhofstiege (Postfix) with ESMTP id 5FC1216819
	for <submit@bugs.debian.org>; Sat, 18 Sep 2004 15:01:34 +0200 (CEST)
Received: by doppler.strudlhofstiege (Postfix, from userid 1000)
	id 51E452BC9B; Sat, 18 Sep 2004 15:01:34 +0200 (CEST)
Date: Sat, 18 Sep 2004 15:01:33 +0200
From: Claus Fischer <claus.fischer@clausfischer.com>
To: submit@bugs.debian.org
Subject: Valgrind bug probably due to libc6
Message-ID: <20040918130133.GA2827@clausfischer.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
User-Agent: Mutt/1.5.6+20040722i
Delivered-To: submit@bugs.debian.org
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2004_03_25 
	(1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-8.0 required=4.0 tests=BAYES_00,HAS_PACKAGE 
	autolearn=no version=2.60-bugs.debian.org_2004_03_25
X-Spam-Level: 

Package: libc6
Version: 2.3.2.ds1-16


Valgrind problem on most recent Sarge (18 Sep 2004).
====================================================

I'm not completely sure whether the bug is due to libc6,
but that's my best guess.

A rather large program of mine, when compiled and run with
valgrind on the latest sarge, gets a SIGSEGV signal:

$ valgrind ./eisclient 
==2714== Memcheck, a memory error detector for x86-linux.
==2714== Copyright (C) 2002-2004, and GNU GPL'd, by Julian Seward et al.
==2714== Using valgrind-2.2.0, a program supervision framework for x86-linux.
==2714== Copyright (C) 2000-2004, and GNU GPL'd, by Julian Seward et al.
==2714== For more details, rerun with: -v
==2714== 
==2714== 
==2714== Process terminating with default action of signal 11 (SIGSEGV): dumping core
==2714==    at 0x1B8EA23C: _dl_map_object (in /lib/ld-2.3.2.so)
==2714==    by 0x1B8EEA18: (within /lib/ld-2.3.2.so)
==2714==    by 0x1B8EFF25: _dl_catch_error (in /lib/ld-2.3.2.so)
==2714==    by 0x1B8EF490: _dl_map_object_deps (in /lib/ld-2.3.2.so)
==2714== 
==2714== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0)
==2714== malloc/free: in use at exit: 0 bytes in 0 blocks.
==2714== malloc/free: 0 allocs, 0 frees, 0 bytes allocated.
==2714== For a detailed leak analysis,  rerun with: --leak-check=yes
==2714== For counts of detected errors, rerun with: -v
Segmentation fault
$ ldd eisclient
        libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0x40026000)
        libm.so.6 => /lib/libm.so.6 (0x400e0000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x40102000)
        libc.so.6 => /lib/libc.so.6 (0x4010c000)
        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)


The same binary runs fine with valgrind on a slightly older Sarge,
without the SIGSEGV. With the same /usr/bin/valgrind.bin, the only
apparent difference is in the libc packages:
2.3.2.ds1-16 triggers the bug, 2.3.2.ds1-13 doesn't.



I found a small program to trigger the same bug on the Internet:
    #include <dlfcn.h>
    
    int main( int argc, char* argv[] )
    {
        void *handle;
        handle = dlopen( argv[1], RTLD_LAZY );
        dlclose( handle );
    }
Compile with g++ -o main main.c -ldl, then run with valgrind.
The error messages are identical to above, even the addresses
reported by valgrind are the same.


I have put my binary of this small program on a website
http://www.clausfischer.com/valgrind-bug in order to exclude
influence of different compilers.

The problem exists both with valgrind versions 2.1.2-2 and
2.2.0-2.

-- 
Claus Fischer <claus.fischer@clausfischer.com>
http://www.clausfischer.com/

---------------------------------------
Received: (at 272219-done) by bugs.debian.org; 25 Sep 2004 02:10:53 +0000
>From gotom@debian.or.jp Fri Sep 24 19:10:53 2004
Return-path: <gotom@debian.or.jp>
Received: from omega.webmasters.gr.jp (webmasters.gr.jp) [218.44.239.78] 
	by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
	id 1CB21V-0001Qx-00; Fri, 24 Sep 2004 19:10:53 -0700
Received: from omega.webmasters.gr.jp (localhost [127.0.0.1])
	by webmasters.gr.jp (Postfix) with ESMTP
	id 877C7DEB80; Sat, 25 Sep 2004 11:10:52 +0900 (JST)
Date: Sat, 25 Sep 2004 11:10:52 +0900
Message-ID: <81wtyjnln7.wl@omega.webmasters.gr.jp>
From: GOTO Masanori <gotom@debian.or.jp>
To: Claus Fischer <claus.fischer@clausfischer.com>,
	272219-done@bugs.debian.org
Subject: Re: Bug#272219: Valgrind bug probably due to libc6
In-Reply-To: <20040918130133.GA2827@clausfischer.com>
References: <20040918130133.GA2827@clausfischer.com>
User-Agent: Wanderlust/2.9.9 (Unchained Melody) SEMI/1.14.3 (Ushinoya)
 FLIM/1.14.3 (=?ISO-8859-4?Q?Unebigory=F2mae?=) APEL/10.3 Emacs/21.2
 (i386-debian-linux-gnu) MULE/5.0 (SAKAKI)
MIME-Version: 1.0 (generated by SEMI 1.14.3 - "Ushinoya")
Content-Type: text/plain; charset=US-ASCII
Delivered-To: 272219-done@bugs.debian.org
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2004_03_25 
	(1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-6.0 required=4.0 tests=BAYES_00,HAS_BUG_NUMBER 
	autolearn=no version=2.60-bugs.debian.org_2004_03_25
X-Spam-Level: 

At Sat, 18 Sep 2004 15:01:33 +0200,
Claus Fischer wrote:
> I'm not completely sure whether the bug is due to libc6,
> but that's my best guess.
> 
> A rather large program of mine, when compiled and run with
> valgrind on the latest sarge, gets a SIGSEGV signal:
>
> I found a small program to trigger the same bug on the Internet:
>     #include <dlfcn.h>
>     
>     int main( int argc, char* argv[] )
>     {
>         void *handle;
>         handle = dlopen( argv[1], RTLD_LAZY );
>         dlclose( handle );
>     }
> Compile with g++ -o main main.c -ldl, then run with valgrind.
> The error messages are identical to above, even the addresses
> reported by valgrind are the same.

Read man dlopen.  When you see break, handle should be NULL pointer.
Try:

	valgrind ./main /lib/libc.so.6

I close this report because it's not bug.

Regards,
-- gotom



Reply to: