[PATCH] mailoop-test #2



This patch also works and sdoesn't rely on g_usleep but on waiting for the
threads to start and get to the point where they add their context to the
array before it continues.

Index: mainloop-test.c
===================================================================
RCS file: /cvs/gnome/glib/tests/mainloop-test.c,v
retrieving revision 1.4
diff -u -r1.4 mainloop-test.c
--- mainloop-test.c 2001/01/06 03:09:46 1.4
+++ mainloop-test.c 2001/03/19 23:24:44
@@ -392,6 +390,8 @@

   for (i = 0; i < NTHREADS; i++)
     create_adder_thread ();
+
+  while (context_array->len < NTHREADS - 1){}

   for (i = 0; i < NCRAWLERS; i++)
     create_crawler ();






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