This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Bug linuxthreads/4338] New: pthread_create / pthread_exit -- use of partially uninitialized buffer


Hello,

You attempt to "nullize" a null pointer (param) in thread_func().
What's happen if you remove param = NULL ?

static void * thread_func (void * param)
{
       param = NULL;

       printf ("Thread created\n");
       usleep(200000);
       printf ("Thread working\n");
       usleep(1200000);
       printf ("Thread ended\n");
       pthread_exit(NULL);
}

Regards, Michael Vergoz


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]