X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/dccf1b41e9c7b5a696f01abceaa2779fe65f154f..a92d7b716f51a53dea7f59db8524d4add713b910:/src/bindings/lua/lua_host.cpp diff --git a/src/bindings/lua/lua_host.cpp b/src/bindings/lua/lua_host.cpp index c83873f610..4d4eac910a 100644 --- a/src/bindings/lua/lua_host.cpp +++ b/src/bindings/lua/lua_host.cpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2010, 2012-2015. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2010-2017. The SimGrid Team. All rights reserved. */ /* 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. */ @@ -7,8 +6,7 @@ /* SimGrid Lua bindings */ #include "lua_private.h" -#include -#include +#include "simgrid/s4u/Host.hpp" extern "C" { #include } @@ -36,7 +34,7 @@ sg_host_t sglua_check_host(lua_State * L, int index) if (pi == nullptr) XBT_ERROR("luaL_checkudata() returned nullptr"); sg_host_t ht = *pi; - if (!ht) + if (not ht) luaL_error(L, "null Host"); return ht; }