Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Due to recent "improvements" in the smpi mpich rma tests, netbsd timeouts. Avoid...
[simgrid.git] / examples / msg / energy-onoff / energy-onoff.c
index 5462489bcc5e28466df10bd6a15e9b2fa97d0d81..17ae54ad404d9c74e441ff2ad9c11f4699a74976 100644 (file)
@@ -84,8 +84,7 @@ static int onoff(int argc, char *argv[]) {
 
 int main(int argc, char *argv[])
 {
-  msg_error_t res = MSG_OK;
-  sg_energy_plugin_init();
+  sg_host_energy_plugin_init();
   MSG_init(&argc, argv);
 
   xbt_assert(argc == 2, "Usage: %s platform_file\n\tExample: %s msg_platform.xml\n", argv[0], argv[0]);
@@ -94,7 +93,7 @@ int main(int argc, char *argv[])
 
   MSG_process_create("onoff_test", onoff, NULL, MSG_get_host_by_name("MyHost2"));
 
-  res = MSG_main();
+  msg_error_t res = MSG_main();
 
   XBT_INFO("Total simulation time: %.2f", MSG_get_clock());