X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/17426e6da9e3e452fcc304e77af71c28a71f5c5c..56d5fef422211eb776ae8d6205816d382e26ecec:/examples/msg/semaphores/synchro.c?ds=sidebyside diff --git a/examples/msg/semaphores/synchro.c b/examples/msg/semaphores/synchro.c index b63a759415..b66b1d3ad3 100644 --- a/examples/msg/semaphores/synchro.c +++ b/examples/msg/semaphores/synchro.c @@ -8,7 +8,7 @@ XBT_LOG_NEW_DEFAULT_CATEGORY(msg_semaphore_example, msg_sem_t sem; -int peer(int argc, char* argv[]){ +static int peer(int argc, char* argv[]){ int i = 0; @@ -27,6 +27,8 @@ int peer(int argc, char* argv[]){ } MSG_process_sleep(50); XBT_INFO("Done"); + + return 0; } int main(int argc, char* argv[]) { @@ -70,5 +72,5 @@ int main(int argc, char* argv[]) { msg_error_t res = MSG_main(); printf("Finished\n"); - return 0; + return (res != MSG_OK); }