|
From: <sv...@va...> - 2005-05-31 17:24:57
|
Author: sewardj
Date: 2005-05-31 18:24:49 +0100 (Tue, 31 May 2005)
New Revision: 3825
Modified:
trunk/coregrind/m_scheduler/scheduler.c
Log:
Completely zero out all the thread records at initialisation. As far
as I can see, deallocate_LGDTs_for_thread were being called on
uninitialised thread records.
Modified: trunk/coregrind/m_scheduler/scheduler.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/coregrind/m_scheduler/scheduler.c 2005-05-31 15:41:42 UTC (rev =
3824)
+++ trunk/coregrind/m_scheduler/scheduler.c 2005-05-31 17:24:49 UTC (rev =
3825)
@@ -632,8 +632,12 @@
VG_(sema_init)(&run_sema);
=20
for (i =3D 0 /* NB; not 1 */; i < VG_N_THREADS; i++) {
- VG_(threads)[i].sig_queue =3D NULL;
=20
+ /* Paranoia .. completely zero it out. */
+ VG_(memset)( & VG_(threads)[i], 0, sizeof( VG_(threads)[i] ) );
+
+ VG_(threads)[i].sig_queue =3D NULL;
+
VGO_(os_state_init)(&VG_(threads)[i]);
mostly_clear_thread_record(i);
=20
|