httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rüdiger Plüm <ruediger.pl...@vodafone.com>
Subject Fwd: svn commit: r1369656 - in /httpd/httpd/trunk/modules/lua: lua_vmprep.c lua_vmprep.h mod_lua.c mod_lua.h
Date Mon, 06 Aug 2012 07:23:16 GMT


-------- Original Message --------
Subject: 	svn commit: r1369656 - in /httpd/httpd/trunk/modules/lua: lua_vmprep.c lua_vmprep.h
mod_lua.c mod_lua.h
Date: 	Sun, 05 Aug 2012 19:57:45 GMT
From: 	humbedooh@apache.org



Author: humbedooh
Date: Sun Aug  5 19:57:44 2012
New Revision: 1369656

URL: http://svn.apache.org/viewvc?rev=1369656&view=rev
Log:
Add a server scope for Lua states (in LuaScope), which creates a pool of  states with manageable
minimum and maximum size.

Modified:
      httpd/httpd/trunk/modules/lua/lua_vmprep.c
      httpd/httpd/trunk/modules/lua/lua_vmprep.h
      httpd/httpd/trunk/modules/lua/mod_lua.c
      httpd/httpd/trunk/modules/lua/mod_lua.h

Modified: httpd/httpd/trunk/modules/lua/lua_vmprep.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/lua/lua_vmprep.c?rev=1369656&r1=1369655&r2=1369656&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/lua/lua_vmprep.c (original)
+++ httpd/httpd/trunk/modules/lua/lua_vmprep.c Sun Aug  5 19:57:44 2012
@@ -23,6 +23,15 @@

   APLOG_USE_MODULE(lua);

+#if APR_HAS_THREADS
+    apr_thread_mutex_t *ap_lua_mutex;
+
+void ap_lua_init_mutex(apr_pool_t *pool, server_rec *s)
+{
+    apr_thread_mutex_create(&ap_lua_mutex, APR_THREAD_MUTEX_DEFAULT, pool);
+}
+#endif
+

Shouldn't you use the httpd mutex API here to keep the mutex type configureable in a generic
way?
See util_mutex.c / ap_mutex_register.

Regards

Rüdiger



Mime
View raw message