Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Merge branch 'master' into actor-priority
[simgrid.git] / src / bindings / lua / lua_platf.cpp
index cddfe8a..6f45328 100644 (file)
@@ -5,7 +5,7 @@
 
 /* SimGrid Lua bindings                                                     */
 
-#include "lua_private.h"
+#include "lua_private.hpp"
 #include "src/kernel/routing/NetPoint.hpp"
 #include "src/surf/network_interface.hpp"
 #include "src/surf/xml/platf_private.hpp"
@@ -16,7 +16,7 @@ extern "C" {
 #include <lauxlib.h>
 }
 
-#include "src/surf/surf_private.h"
+#include "src/surf/surf_private.hpp"
 #include <boost/algorithm/string/classification.hpp>
 #include <boost/algorithm/string/split.hpp>
 #include <simgrid/s4u/Host.hpp>
@@ -90,8 +90,9 @@ int console_add_backbone(lua_State *L) {
   lua_pop(L, 1);
 
   lua_pushstring(L, "sharing_policy");
-  type = lua_gettable(L, -2);
+  lua_gettable(L, -2);
   const char* policy = lua_tostring(L, -1);
+  lua_pop(L, 1);
   if (policy && not strcmp(policy, "FULLDUPLEX")) {
     link.policy = SURF_LINK_FULLDUPLEX;
   } else if (policy && not strcmp(policy, "FATPIPE")) {