Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Comsetics
[simgrid.git] / examples / msg / io / file.c
index ed8e91a..b419a3a 100644 (file)
  * - <b>io/file.c</b> Example with the disk resource
  */
 
-#define FILENAME1 "/home/user/Install/simgrid/doc/simgrid/examples/platforms/g5k.xml"
-#define FILENAME2 "/home/user/Install/simgrid/doc/simgrid/examples/platforms/One_cluster_no_backbone.xml"
-#define FILENAME3 "/home/user/Install/simgrid/doc/simgrid/examples/platforms/g5k_cabinets.xml"
-#define FILENAME4 "/home/user/Install/simgrid/doc/simgrid/examples/platforms/nancy.xml"
+#define FILENAME1 "./doc/simgrid/examples/platforms/g5k.xml"
+#define FILENAME2 "./doc/simgrid/examples/platforms/One_cluster_no_backbone.xml"
+#define FILENAME3 "./doc/simgrid/examples/platforms/g5k_cabinets.xml"
+#define FILENAME4 "./doc/simgrid/examples/platforms/nancy.xml"
 
 #include <stdio.h>
 #include <stdlib.h>
@@ -60,7 +60,7 @@ int host(int argc, char *argv[])
   XBT_INFO("\tHaving read  %zu \ton %s",read,file->name);
 
   MSG_file_stat(file,&stat);
-  XBT_INFO("\tFile %s Size %d",file->name,(int)stat.size);
+  XBT_INFO("\tFile stat %s Size %d",file->name,(int)stat.size);
 
   XBT_INFO("\tClose file '%s'",file->name);
   MSG_file_close(file);
@@ -71,8 +71,8 @@ int host(int argc, char *argv[])
 
 int main(int argc, char **argv)
 {
-    int i,res;
-  MSG_global_init(&argc, argv);
+  int i,res;
+  MSG_init(&argc, argv);
   MSG_create_environment(argv[1]);
   xbt_dynar_t hosts =  MSG_hosts_as_dynar();
   MSG_function_register("host", host);