X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/7a8cd62135619ad52e05ae1c929ef07e166e4260..347996b4a10c4e8579080692afa60e0afb88b60a:/examples/msg/tracing/categories.c diff --git a/examples/msg/tracing/categories.c b/examples/msg/tracing/categories.c index bb6d765e1a..f5e3fc95e8 100644 --- a/examples/msg/tracing/categories.c +++ b/examples/msg/tracing/categories.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2010. The SimGrid Team. +/* Copyright (c) 2010-2015. The SimGrid Team. * All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it @@ -12,16 +12,16 @@ * used to classify tasks. When the program is executed, the tracing mechanism registers * the resource utilization of hosts and links according to these categories. You might * want to run this program with the following parameters: - * --cfg=tracing:1 - * --cfg=tracing/categorized:1 - * --cfg=tracing/uncategorized:1 + * --cfg=tracing:yes + * --cfg=tracing/categorized:yes + * --cfg=tracing/uncategorized:yes * --cfg=viva/categorized:viva_cat.plist * --cfg=viva/uncategorized:viva_uncat.plist * (See \ref tracing_tracing_options for details) */ #include -#include "msg/msg.h" +#include "simgrid/msg.h" #include "xbt/sysdep.h" /* calloc, printf */ /* Create a log channel to have nice outputs. */ @@ -32,11 +32,11 @@ XBT_LOG_NEW_DEFAULT_CATEGORY(msg_test, int master(int argc, char *argv[]); int slave(int argc, char *argv[]); -/** Emitter function */ +/** sender function */ int master(int argc, char *argv[]) { - long number_of_tasks = atol(argv[1]); - long slaves_count = atol(argv[4]); + long number_of_tasks = xbt_str_parse_int(argv[1], "Invalid amount of tasks: %s"); + long slaves_count = xbt_str_parse_int(argv[4], "Invalid amount of slaves: %s"); int i; for (i = 0; i < number_of_tasks; i++) {