httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From poir...@apache.org
Subject svn commit: r939980 - /httpd/httpd/trunk/modules/lua/lua_config.c
Date Sat, 01 May 2010 11:43:55 GMT
Author: poirier
Date: Sat May  1 11:43:55 2010
New Revision: 939980

URL: http://svn.apache.org/viewvc?rev=939980&view=rev
Log:
An uninitialized pointer in ap_lua_mapped_handler_spec was causing
seg faults in lua.

Modified:
    httpd/httpd/trunk/modules/lua/lua_config.c

Modified: httpd/httpd/trunk/modules/lua/lua_config.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/lua/lua_config.c?rev=939980&r1=939979&r2=939980&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/lua/lua_config.c (original)
+++ httpd/httpd/trunk/modules/lua/lua_config.c Sat May  1 11:43:55 2010
@@ -58,7 +58,7 @@ AP_LUA_DECLARE(apr_status_t) ap_lua_map_
     ap_regex_t *uri_pattern;
     apr_status_t rv;
     ap_lua_mapped_handler_spec *handler =
-        apr_palloc(cfg->pool, sizeof(ap_lua_mapped_handler_spec));
+        apr_pcalloc(cfg->pool, sizeof(ap_lua_mapped_handler_spec));
     handler->uri_pattern = NULL;
     handler->function_name = NULL;
 
@@ -81,7 +81,7 @@ static int cfg_lua_map_handler(lua_State
 {
     ap_lua_dir_cfg *cfg = check_dir_config(L, 1);
     ap_lua_mapped_handler_spec *handler =
-        apr_palloc(cfg->pool, sizeof(ap_lua_mapped_handler_spec));
+        apr_pcalloc(cfg->pool, sizeof(ap_lua_mapped_handler_spec));
     handler->uri_pattern = NULL;
     handler->function_name = NULL;
 



Mime
View raw message