X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/11667312f9c0886b8e7b6ca908266d33d2282b13..cce6ab4f4fb2bbc73b9d440c72ded7eb9be95f3d:/teshsuite/simdag/basic-parsing-test/basic-parsing-test.c diff --git a/teshsuite/simdag/basic-parsing-test/basic-parsing-test.c b/teshsuite/simdag/basic-parsing-test/basic-parsing-test.c index e8a056c6bf..5464341c26 100644 --- a/teshsuite/simdag/basic-parsing-test/basic-parsing-test.c +++ b/teshsuite/simdag/basic-parsing-test/basic-parsing-test.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2008-2015. The SimGrid Team. +/* Copyright (c) 2008-2020. The SimGrid Team. * All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it @@ -18,8 +18,8 @@ int main(int argc, char **argv) sg_host_t *hosts = sg_host_list(); if (argc >= 3) { if (!strcmp(argv[2], "ONE_LINK")) { - sg_host_t h1 = hosts[0]; - sg_host_t h2 = hosts[1]; + const_sg_host_t h1 = hosts[0]; + const_sg_host_t h2 = hosts[1]; const char *name1 = sg_host_get_name(h1); const char *name2 = sg_host_get_name(h2); @@ -37,12 +37,12 @@ int main(int argc, char **argv) xbt_dynar_free_container(&route); } if (!strcmp(argv[2], "FULL_LINK")) { - int list_size = sg_host_count(); - for (int i = 0; i < list_size; i++) { - sg_host_t h1 = hosts[i]; + size_t list_size = sg_host_count(); + for (size_t i = 0; i < list_size; i++) { + const_sg_host_t h1 = hosts[i]; const char *name1 = sg_host_get_name(h1); - for (int j = 0; j < list_size; j++) { - sg_host_t h2 = hosts[j]; + for (size_t j = 0; j < list_size; j++) { + const_sg_host_t h2 = hosts[j]; const char *name2 = sg_host_get_name(h2); fprintf(stderr, "Route between %s and %s\n", name1, name2); xbt_dynar_t route = xbt_dynar_new(sizeof(SD_link_t), NULL); @@ -64,6 +64,5 @@ int main(int argc, char **argv) } xbt_free(hosts); - SD_exit(); return 0; }