]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds/Mantle: Fixed Mantle's obsolete Lua C++ API
authorTsung-Ju Lii <usefulalgorithm@gmail.com>
Tue, 26 Jun 2018 02:57:51 +0000 (10:57 +0800)
committerTsung-Ju Lii <usefulalgorithm@gmail.com>
Tue, 26 Jun 2018 03:45:05 +0000 (11:45 +0800)
Changed Mantle's Lua C++ API from using several `luaopen_*` calls to
one `luaL_openlibs` call, since the former has been deprecated from the
release of Lua 5.1.

Signed-off-by: Tsung-Ju (Andy Lii) <usefulalgorithm@gmail.com>
src/mds/Mantle.cc

index 08e601770c63c27430061d6c8801ab703378f7c9..8bf79c4c00d339438c82b4bb98bd2b4e681d85c2 100644 (file)
@@ -119,12 +119,7 @@ Mantle::Mantle (void)
   }
 
   /* balancer policies can use basic Lua functions */
-  luaopen_base(L);
-  luaopen_coroutine(L);
-  luaopen_string(L);
-  luaopen_math(L);
-  luaopen_table(L);
-  luaopen_utf8(L);
+  luaL_openlibs(L);
 
   /* setup debugging */
   lua_register(L, "BAL_LOG", dout_wrapper);