Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Display errno on error.
[simgrid.git] / src / simix / smx_context.cpp
index 5dbbfb2..6f32bb1 100644 (file)
@@ -5,23 +5,12 @@
 /* This program is free software; you can redistribute it and/or modify it
  * under the terms of the license (GNU LGPL) which comes with this package. */
 
-#include <xbt/config.hpp>
-#include <xbt/log.h>
-#include <xbt/range.hpp>
-#include <xbt/sysdep.h>
-
 #include "simgrid/modelchecker.h"
-#include "simgrid/sg_config.hpp"
-#include "smx_private.hpp"
 #include "src/internal_config.h"
-#include "xbt/log.h"
-#include "xbt/xbt_os_thread.h"
+#include "src/simix/smx_private.hpp"
+#include "xbt/config.hpp"
 
-#include <cerrno>
-#include <cstring>
-#include <string>
 #include <thread>
-#include <utility>
 
 #ifdef _WIN32
 #include <windows.h>
@@ -112,7 +101,7 @@ void SIMIX_context_mod_init()
 #endif
 
   /* select the context factory to use to create the contexts */
-  if (simgrid::kernel::context::factory_initializer) { // Give Java a chance to hijack the factory mechanism
+  if (simgrid::kernel::context::factory_initializer != nullptr) { // Give Java a chance to hijack the factory mechanism
     simix_global->context_factory = simgrid::kernel::context::factory_initializer();
     return;
   }