From 441613bf23533f272722d88b161328abe2a0993d Mon Sep 17 00:00:00 2001 From: pixel Date: Wed, 13 Aug 2008 09:39:54 +0000 Subject: Adding double-loading locks --- src/plugin-luaregex.cc | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/plugin-luaregex.cc') diff --git a/src/plugin-luaregex.cc b/src/plugin-luaregex.cc index 13be506..739d8f9 100644 --- a/src/plugin-luaregex.cc +++ b/src/plugin-luaregex.cc @@ -7,6 +7,9 @@ #endif static void _init_plugin(Lua * L) { + static bool done = false; + if (done) return; + done = true; LuaRegex::pushstatics(L); } -- cgit v1.2.3