X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/a34aa584ccd2bdb81659d0e5df22864cf999c0f4..8192acecf44818a829583724900211221500a718:/teshsuite/msg/get_sender.c diff --git a/teshsuite/msg/get_sender.c b/teshsuite/msg/get_sender.c index b9ffa48829..c6237bdc2d 100644 --- a/teshsuite/msg/get_sender.c +++ b/teshsuite/msg/get_sender.c @@ -28,6 +28,7 @@ static int receive(int argc, char *argv[]) xbt_assert(MSG_task_get_sender(task), "No sender received"); XBT_INFO("Got a message sent by '%s'", MSG_process_get_name(MSG_task_get_sender(task))); + MSG_task_destroy(task); return 0; } @@ -43,9 +44,9 @@ int main(int argc, char *argv[]) MSG_function_register("receive", &receive); MSG_create_environment(argv[1]); - MSG_launch_application(argv[1]); + MSG_launch_application(argv[2]); res = MSG_main(); - MSG_clean(); + if (res == MSG_OK) return 0; else