From: Arnaud Giersch Date: Fri, 23 Nov 2012 08:34:07 +0000 (+0100) Subject: Move check at another place where it doesn't break the log machinery. X-Git-Tag: v3_9_rc1~91^2~47^2~7 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/6139ac45b7aebbc5c54f8a644843f78e88d5e2be?ds=inline Move check at another place where it doesn't break the log machinery. --- diff --git a/src/simix/smx_private.h b/src/simix/smx_private.h index 9cbceaa018..257ea0e9d6 100644 --- a/src/simix/smx_private.h +++ b/src/simix/smx_private.h @@ -258,7 +258,8 @@ static XBT_INLINE smx_context_t SIMIX_context_new(xbt_main_func_t code, void_pfn_smxprocess_t cleanup_func, smx_process_t simix_process) { - + if (!simix_global) + xbt_die("simix is not initialized, please call MSG_init first"); return simix_global->context_factory->create_context(code, argc, argv, cleanup_func, @@ -312,8 +313,6 @@ static XBT_INLINE smx_context_t SIMIX_context_self(void) if (simix_global && simix_global->context_factory) { return simix_global->context_factory->self(); } - - xbt_die("simix is not initialized, please call MSG_init first"); return NULL; }