|
From: Nemec, B. <Ber...@vi...> - 2005-07-01 08:58:54
|
Hello list,
I'm getting the following leak report from Valgrind 2.4.0, and would
like to know whether this belongs in the suppressions file or it's my
fault:
==13888== 68 bytes in 1 blocks are possibly lost in loss record 1 of 1
==13888== at 0x25985BC9: calloc (vg_replace_malloc.c:175)
==13888== by 0x259734EA: _dl_allocate_tls (in /lib/ld-2.3.3.so)
==13888== by 0x48D78D: pthread_create@@GLIBC_2.1 (in
/lib/tls/libpthread-2.3.3.so)
==13888== by 0x80484D7: main (main.c:18)
My test code is the following:
#include <stdio.h>
#include <unistd.h>
#include <pthread.h>
void* threadfunc( void* arg )
{
printf( "a\n" );
sleep(2);
printf( "b\n" );
return 0;
}
int main( int argc, char** argv )
{
pthread_t tid;
printf( "hello\n" );
if ( 0 == pthread_create( &tid, 0, &threadfunc, 0 ) ){
pthread_join( tid, 0 );
}
printf( "goodbye\n" );
return 0;
}
I compile it with gcc -g -Wall -o test_threads -lpthread test_threads.c,
using gcc 3.4.2 on Fedora Core 3.
Thank you!
Bernhard
DISCLAIMER:
This information and any attachments contained in this email message is
intended only for the use of the individual or entity to which it is
addressed and may contain information that is privileged, confidential,
and exempt from disclosure under applicable law. If the reader of this
message is not the intended recipient, or the employee or agent
responsible for delivering the message to the intended recipient, you are
hereby notified that any dissemination, distribution, forwarding, or
copying of this communication is strictly prohibited. If you have
received this communication in error, please notify the sender immediately
by return email, and delete the original message immediately.
|
|
From: Nicholas N. <nj...@cs...> - 2005-07-01 12:51:48
|
On Fri, 1 Jul 2005, Nemec, Bernhard wrote: > I'm getting the following leak report from Valgrind 2.4.0, and would > like to know whether this belongs in the suppressions file or it's my > fault: I think it's one to suppress. N |