X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/a42c95e1e1dc366c25740f1e80be435e44cba993..dff9e15c44ab6340d27215957c56fa72fad246a2:/teshsuite/xbt/parallel_log_crashtest.c diff --git a/teshsuite/xbt/parallel_log_crashtest.c b/teshsuite/xbt/parallel_log_crashtest.c index 0ced8a5ebf..3d55f8c4eb 100644 --- a/teshsuite/xbt/parallel_log_crashtest.c +++ b/teshsuite/xbt/parallel_log_crashtest.c @@ -10,14 +10,14 @@ #include "gras.h" #include "xbt/synchro.h" -XBT_LOG_NEW_DEFAULT_CATEGORY(synchro_crashtest,"Logs of this example"); +XBT_LOG_NEW_DEFAULT_CATEGORY(synchro_crashtest, "Logs of this example"); -int test_amount = 99; /* Up to 999 to not break the logs (and thus the testing mecanism) */ -int crasher_amount = 99; /* Up to 99 to not break the logs (and thus the testing mecanism) */ -int *id; /* to pass a pointer to the threads without race condition */ +int test_amount = 99; /* Up to 999 to not break the logs (and thus the testing mecanism) */ +int crasher_amount = 99; /* Up to 99 to not break the logs (and thus the testing mecanism) */ +int *id; /* to pass a pointer to the threads without race condition */ -int more_info=0; /* SET IT TO TRUE TO GET MORE INFO */ +int more_info = 0; /* SET IT TO TRUE TO GET MORE INFO */ /* * Some additionnal code to let the father wait the childs @@ -29,36 +29,39 @@ int running_threads; xbt_mutex_t dead_end; /* Code ran by each thread */ -static void crasher_thread(void *arg) { - int id = *(int*)arg; - int i; - - for (i=0; i